Re: session_unset doesn't end the session. Was: [PHP-DEV] Sessions - lack of support for endingn a session and beginning a new one.
| From: | Daniel Beckham | Date: | Mon, 05 Jun 2000 21:24:01 +0000 |
| Subject: | Re: session_unset doesn't end the session. Was: [PHP-DEV] Sessions - lack of support for endingn a session and beginning a new one. | ||
| References: | 1 2 3 4 5 6 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-20288@lists.php.net to get a copy of this message | ||
I'd like to clear up my observations on this matter. It does appear that:
session_destroy()
session_start()
will resume a different session if HTTP_COOKIE_VARS["PHPSESSID"] is populated with the needed session id. I was using $PHPSESSID which is a copy of the HTTP_COOKIE_VARS["PHPSESSID"] array element and will not work.
One thing that doesn't seem to happen, is that after session_start() is called for the second time, no new cookie is set with the new session id. If I call:
header("SetCookie: blah, blah");
after session_start(), the cookie is passed around again and the sessions will work past the current script. Not sure if this is something that they session maintainer might like to look into.
Thank you for your time,
Daniel