Page 1 of 1

Sessions...

Posted: Wed Jan 23, 2008 11:41 am
by jkashu
I am very unexperienced with sessions...

I'm using a login script that uses sessions. The problem is that if somebody logs into http://www.thewebsite.com and logouts from thewebsite.com/logout.php (no WWW is the key), they remain logged in.

Can I have the session recognized http://www.thewebsite.com and just http://thewebsite.com as the same thing????

Does this make sense?

Thanks!

Re: Sessions...

Posted: Wed Jan 23, 2008 11:46 am
by Zoxive
That is because the cookie(For Session ID) is not being set to span across sub domains.

Change session.cookie_domain to ".domain.com" in php.ini or .htaccess

.htaccess

Code: Select all

php_value session.cookie_domain = ".domain.com"

Re: Sessions...

Posted: Wed Jan 23, 2008 12:00 pm
by jkashu
When I put that line in the .htaccess file, it gives me a internal server error. Is there anything else I need to do? How do I change the php.ini?
thanks!