[EMAIL PROTECTED] wrote:
Code Iım using:
session_cache_expire(0); session_cache_limiter('private'); setcookie("cookie","",0,"/","iffinet.com",1); session_start();
I use session_destroy(); in the logout function but the /tmp/sess_* file does not get deleted. Also the cookie doesnıt go away even though it is set to expire at the end of the session. How can I get the /tmp/sess_* file to go away along with the cookie?
This is a description of the problems I am having:
2 Problems:
1. User A's information will come up when user B logs in instead of user B's information coming up when user B logs in... User A's information seems to be cached in /tmp/sess_8ce0348cbf6704f96c2d8094e876ac3b. Any ideas how to keep this from happening?
2. When a user exits Internet Explorer without logging off and invoking session_destroy(); the user cannot log back in immediately. If I SSH into the server and delete /tmp/sess_8ce0348cbf6704f96c2d8094e876ac3b then the user can log back in.
Do I need to write a shell_exec routine to delete this file when the session
is destroyed? How can I tell from the server that the user has closed the
window?
Thanks again!
/T
You ought to check whether session_destroy() succeeds in removing the respective sess_* file. session_destroy() returns a boolean value.
Be aware that session_destroy() won't remove any existing cookies.
Also you should take a look at this notice (http://www.php.net/manual/en/function.session-cache-limiter.php):
[snip]
In private mode, the Expire header sent to the client may cause confusion for some browsers, including Mozilla. You can avoid this problem by using private_no_expire mode. The expire header is never sent to the client in this mode.
[/snip]
Daniel
-- WWE e-commerce IT GmbH Eiffestrasse 462, D-20537 Hamburg Tel.: +49-40-2530659-0, Fax: +49-40-2530659-50
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php