Dragen Posted April 10, 2007 Share Posted April 10, 2007 what am I doing wrong? I've got a link like this: <a href="dispcalendar.php?month=1&year=2007">view the calendar for the rest of the year.</a> then on dispcalendar.php I have: showYear($month, $year); But it doesn't seem to be reading the values sent in the url as I just get a blank page. Thanks Quote Link to comment https://forums.phpfreaks.com/topic/46503-solved-error-reading-values-from-url/ Share on other sites More sharing options...
pocobueno1388 Posted April 10, 2007 Share Posted April 10, 2007 Can you show us more code? Did you define your variables like this: $month = $_GET['month']; $year = $_GET['year']; Quote Link to comment https://forums.phpfreaks.com/topic/46503-solved-error-reading-values-from-url/#findComment-226293 Share on other sites More sharing options...
kenrbnsn Posted April 10, 2007 Share Posted April 10, 2007 You need to get the values from the $_GET superglobal array explicitly: <?php showYear($_GET['month'], $_GET['year']); ?> Ken Quote Link to comment https://forums.phpfreaks.com/topic/46503-solved-error-reading-values-from-url/#findComment-226295 Share on other sites More sharing options...
Dragen Posted April 10, 2007 Author Share Posted April 10, 2007 yeah, thanks.. I just realised I'd missed out that part sorry my fault! Quote Link to comment https://forums.phpfreaks.com/topic/46503-solved-error-reading-values-from-url/#findComment-226297 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.