Re: Re-initiating an autostarted session

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Marek Kilimajer wrote:
You are right, unset($_COOKIES) does not remove cookie from the client.

You need to unset() it so that your next call to session_start() does not use the same $_COOKIES[session_name()]. session_start will generate new session id if there is not one set in the request variables.

I see, thanks! I tried unsetting the cookies and request superglobals, but it still does not give a new session id.

	unset($_COOKIES[session_name()]);
	unset($_REQUEST[session_name()]);
	session_destroy();
	session_start();
	session_write_close();

I will try to use a session_start() instead of an autostarted session (per .htaccess) if it would help the situation.

Ville

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux