register_global, need some feedback
| From: | Scott Fletcher | Date: | Mon, 01 Jul 2002 16:08:55 +0000 |
| Subject: | register_global, need some feedback | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-104705@lists.php.net to get a copy of this message | ||
Hi!
With the register_global turned off. I'm working on making the login to
work again. So, I have a few questions.
1) $GLOBALS, Where does this come from and where does this goes to? I
noticed there is no variable declaration for this, so I just know that it is
part of PHP codes, although I haven't figure out what is it part of.
2) What would be the way to go to make it work, when changing it within this
script with register_global turned on to turned off?
--clip --
while (list($var, $value) = each($GLOBALS[HTTP_POST_VARS])
{
$GLOBALS[$var] = stripslashes(trim($value));
}
reset ($GLOBALS[HTTP_POST_VARS]);
--clip--
I tried different ways to make it work and I kept getting the error saying
" Variable passed to each() is not an array or object "
" Variable passed to reset() is not an array or object "
Thanks
FletchSOD