First, an explanation about what this ini setting does. Let's say the
following URL is used:
http://example.com/foo.php?animal=cat
and in foo.php we might have the following
PHP code:
<?php
// Using $_GET here is preferred
echo $_GET['animal'];
// For $animal to exist, register_globals must be on
// DO NOT DO THIS
echo $animal;
// This applies to all variables, so $_SERVER too
echo $_SERVER['PHP_SELF'];
// Again, for $PHP_SELF to exist, register_globals must be on
// DO NOT DO THIS
echo $PHP_SELF;
?>
The code above demonstrates how register_globals creates a lot of
variables. For years this type of coding has been frowned upon, and for
years it's been disabled by default. Note that PHP will eventually remove this
deprecated feature. So although most web hosts disable register_globals,
there are still outdated articles, tutorials, and books that require it
to be on. Plan accordingly.