Re: new $_SESSION variables vs. session_register/unregister
| From: | Steven Jarvis | Date: | Thu, 28 Mar 2002 19:27:26 +0000 |
| Subject: | Re: new $_SESSION variables vs. session_register/unregister | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-90579@lists.php.net to get a copy of this message | ||
Uh... doh!
I was reading this:
Note: If $_SESSION (or $HTTP_SESSION_VARS for PHP 4.0.6 or less) is used, use unset() to unregister a session variable.
incorrectly.
In my haste, I was basically not parsing the parentheses. I see now that I just treat the $_SESSION variables like any other variable and use unset() and isset() (in place of session_is_registered().
I apologize for the noise.
Steven
On Thursday, March 28, 2002, at 01:21 PM, Steven Jarvis wrote:
The manual says:If you are using $HTTP_SESSION_VARS/$_SESSION, do not use session_register(), session_is_registered() and session_unregister().If that's the case, how do I unregister $_SESSION variables? Do I just use unset() or is there another way? I'm pretty new to PHP and I'm just getting started using sessions. The book I'm using to learn sessions isn't new enough to include how to deal with the new $_SESSION global variables array, and the manual's dire warning isn't explained thoroughly enough for me. Thanks! Steven -- Steven Jarvis Web Developer Arkansas Democrat-Gazette Northwest Edition NWAnews.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php