Hey everbody,
I noticed that many problems regarding PHP are caused by the fact that most people are unaware of the changes PHP made in PHP 4.2.0.
The default value for the PHP directive register_globals went from ON to OFF. Reliance on this directive was quite common and many people didn't even know it existed and assumed it's just how PHP works.
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.
Read more from:PHP Register Globals
Wednesday, March 24, 2004
Subscribe to:
Posts (Atom)