Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
April 8, 2007, 2:28 pm
rate this thread
three years I made upgrade to newest PHP on my local PC and links
stopped to work.
This is the only site I use PHP so I`m just casual user of this
Worked before, not working now.
Whole navigation is made by different value of variable content.
Variable is not posted from form. It is just link.
print $content; prints nothing, so it seems that variable is not
initialized. Why? What have changed between versions 4 and 5 of PHP.
Thanks in advance.
Re: VAriable not initialized in new version of PHP
Regsiter_globals used be enabled by default, it is now disabled. Please
read <http://www.php.net/register_globals for more information. This
setting in the php.ini file controls whether variables on the URL, from
POSTed forms, or in COOKIEs were preset. Now you have to retrieve the
values from the particular superglobal array yourself.
$_GET for forms with method="get" and from variables on the URL
$_POST for forms with method=post"
So in your case, you need to change the code to read