Kang Sun wrote:
Greetings!
I am testing Apache/PHP/MySQL. The connection seems to be right but
when I try to http://my_machine/mypage.php3?id=1", I won't be able to
get value the variable $id. Did I miss anything in the configuration
of Apache or I miss a function call before I check the value of $id in
PHP file?
Please help! Thanks!
Please mail to su******@hotmail.com
-- Kang
"In PHP 4.2.0 and later, the default value for the PHP directive
register_globals is off. This is a major change in PHP. Having
register_globals off affects the set of predefined variables available
in the global scope. For example, to get DOCUMENT_ROOT you'll use
$_SERVER['DOCUMENT_ROOT'] instead of $DOCUMENT_ROOT, or $_GET['id'] from
the URL
http://www.example.com/test.php?id=3 instead of $id, or
$_ENV['HOME'] instead of $HOME.
For related information on this change, read the configuration entry for
register_globals, the security chapter on Using Register Globals , as
well as the PHP 4.1.0 and 4.2.0 Release Announcements.
Using the available PHP Reserved Predefined Variables, like the
superglobal arrays, is preferred."
taken directly from the PHP manaul at
http://www.php.net/manual/en/languag...predefined.php
--
John Downey
http://delusive.dyn.ee http://sage.dev.box.sk http://blacksun.box.sk