ex.php <? $test=60+$page; printf("value of test is $test"); ?> output: "value of test is 60"
how can I make it so that when I go to http://localhost/ex.php?page=7 so the resulting output would be "value of test is 67"?
thanks
Any possibility you're bitten by the register_globals issue?
don't know about the register_globals, I just started php this week.
would I need to register page as a global variable? How would I go about doing that?
edit found it $page = $_GET['page'];
Originally posted by grrmuzzigrr edit found it $page = $_GET['page'];
And all by yourself! You'll be doing great in no time!
(Seriously: this is like the #1 FAQ around here, and can be a pet peeve. Good for you that you can do your own research... 🙂 )