note 70184 deleted from ref.session by danbrown
| From: | danbrown@php.net | Date: | Sun, 20 Jul 2008 16:47:46 +0000 |
| Subject: | note 70184 deleted from ref.session by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-142201@lists.php.net to get a copy of this message | ||
Note Submitter: klenwell at gmail dot com
----
In response to marou at marou dot com responding to fondman at hotmail dot com regarding local
variables overwriting SESSION variables:
I was encountering this same problem. On my local PHP 5 server, no problem. Remote host's
server running PHP 4: major headaches.
Initially, I concluded it was some kind of bug in PHP 4 and older. However, according to the devs,
this is not a bug (see http://bugs.php.net/bug.php?id=36366). Apparently,
this is intended behavior when register_globals is set to ON.
But, as noted elsewhere in the docs, register_globals cannot be turned off at runtime using
ini_set(). However, you can use a local .htaccess or php.ini to override the setting. This site
helped me solve the problem:
http://www.nyphp.org/phundamentals/ini.php
Full details of my experience with this issue can be found here:
http://tinyurl.com/o6p7y