Re: Some SESSION Vars not Registering
| From: | Jeff Stillwall | Date: | Wed, 23 Jul 2003 04:02:04 +0000 |
| Subject: | Re: Some SESSION Vars not Registering | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-156386@lists.php.net to get a copy of this message | ||
"Tom Rogers" wrote:
> I am sure they do not but....
> I just tried reading the docs and it is as clear as mud so its back to
> the suck it and see method
From the on-line docs, regarding $_SESSION (at
http://us3.php.net/manual/en/reserved.variables.php#reserved.variables.sessi
on):
"This is a 'superglobal', or automatic global, variable. This simply means
that it is available in all scopes throughout a script. You don't need to do
a global $_SESSION; to access it within functions or methods, as you do with
$HTTP_SESSION_VARS."
So, this gets more perplexing.
I should also note that I did try to use the global keyword, and it didn't
help. Also, I tried setting the $_SESSION variables in question to
something else ($_SESSION["fname"] = " ") before calling the function.
Didn't help either.
I have just never had a problem with sessions before. But I'm guessing it's
my code, as I can replicate the behavior on three different installations of
PHP/Apache.
--
Jeff Stillwall