Andre Dubuc wrote:

Thought I'd drop a note -- turning register_globals=off on the server in question magically made everything work.

Now I'll rasie the question that IP manager has asked: "Having register_globals=of/on should not amke any difference to your site if you are using $_POST, $_SESSION etc. You must have a bug in your code."

There's one exception to that theory as I've experienced: Sessions. Generally, anything written to work with register_globals OFF will work with them on. You may be introducing security holes, but it'll work.


However, sessions always seem to introduce problems when you go between the settings, or at least how I use them, it does. I always use unset($_SESSION['whatever']) to get rid of a session variable. If register_globals is on, then $whatever still exists and is still saved in the session at the end of the page. It may not work this way with every version of PHP, but I've experienced issues like that in the past.

There are other issues with sessions and switching register_globals settings, too, so if you're program relies upon them heavily, that may be the problem.

--

John Holmes

php|architect - The magazine for PHP professionals - http://www.phparch.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to