Forum Moderators: travelin cat
the server (php or apache I'm not sure) will not recognize variables sent in the URL (not sure of the correct name.) like:
index.php?var=foo On my old system and when I upload to my server it creates a variable called $var and give it "foo" for a value.
on my current server if index.php contained
echo $var; it would not print anything, in fact it thinks the variable doesn't exist.
does anyone know what could be causing this? or has anyone else had a similar problem? this has happened on two separate G5's now. (mine and a friends)
thank you for your time.
-oh and i did turn on PHP, things like includes or anything not involving a sent variable works-
Having register_globals set to on is considered a serious security risk.
For a discussion see here [dk2.php.net...]
$varname = $_GET['varname'];
If the variables are coming from a form instead of in the query string use the following instead:
$varname = $_POST['varname'];
To be safe, you should include some data validation code to be safe (preventing malicious users from sending PHP code as variables).