Problem on getting value.
| From: | Joe Phyism | Date: | Sun, 22 Jun 2003 01:29:17 +0000 |
| Subject: | Problem on getting value. | ||
| Groups: | php.install | ||
| Request: | Send a blank email to php-install+get-11133@lists.php.net to get a copy of this message | ||
Dear all,
I am using Apache 1.3.26 and PHP 4.3.2, running on Windows XP as local web
server, however, I encounter the following problem when I try to execute my
PHP script.
[source of show.php]
<?
if ( $a == 1 ) {
echo "True.";
} else {
echo "False.";
}
?>
[source end]
I try to use IE to see the result, however, no matter
http://localhost/show.php or http://localhost/show.php?a=1, the result is
the same - "False.".
I have asked on php.lang and the problem is generally solved by the
following modification on my script:
<?
if ( $_GET['a'] == 1 ) {
echo "True.";
} else {
echo "False.";
}
?>
But I want to use the script above, how can I change my configuration?
Helper on the newsgroup told me that "If so then you are expecting 'Globals'
to be set as 'on' and they're set to 'off'.", what does that mean?
Thank you very much.