Re: $HTTP_SESSION_VARS with unset()

From: Date: Fri, 15 Mar 2002 00:56:50 +0000
Subject: Re: $HTTP_SESSION_VARS with unset()
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-88601@lists.php.net to get a copy of this message
I must ask first, why don't you just use the session_destroy() function? it will kill all related sessions variables and reset the PHPSESSID (if that's you have it named) Jim Lucas www.bend.com ----- Original Message ----- From: "SpamSucks86" <spamsucks86@comcast.net> To: <php-general@lists.php.net> Sent: Thursday, March 14, 2002 4:54 PM Subject: [PHP] $HTTP_SESSION_VARS with unset() > when someone logs in, it sets $HTTP_SESSION_VARS with the appropriate > information. to log them out, I tried just using > unset($HTTP_SESSION_VARS['valid_user']) but it doesn't actually remove > it from the session. it will only work if valid_user was set on the same > script call (for example, if it logs me in and then immediately logs me > out without making another call to the script). How come > $HTTP_SESSION_VARS won't destroy session variables unless they're > created during the same script call? Or maybe it just has to do with if > $HTTP_SESSION_VARS creates any variable before it deletes any. Thanks > for your help =) >

« previous php.general (#88601) next »