MyBB Community Forums

Full Version: Two forums in one domain have conflict in cookies
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Excuse me if this is reported before. Help me to find the answer if it is.
I have two forums in one domain. one on mybboard.ir and another themes.mybboard.ir ,
Well as usual I have to set each cookie-domain on each site. For example in mybboard.ir's admin, cookie-domain should be set "mybboard.ir" and for other subdomain should be "themes.mybboard.ir".

Ok. look. If first, user comes in first forum and login, then in second one, as cookie set on mybboard.ir and will send on all subdomains the user cant login to second forum... (for some reasons it should not be, and if cookie domain set on .mybboard.ir it should send on all subdomains and not when cookie set on mybboard.ir but it manners this way)
tell me what can I do...

And as a suggestion , a cookie prefix like as other softwares may solves such problems and also may increase some functionalities... BTW someone tell me how to solve the main problem, this is not primary problem...
Thanks.

then user cant switch between two forums.
note that first forum needs a cookie like "sid=xxxx" but second forum "sid=yyyy" for accepting users' request. Obviously if you login to first forum, second one won't work and negative, he logs into second forum he's not able to work with first one Sad
Yes it's a limitation right now.
Yes, we've already had cookie prefixes in 1.4
suggestion ... set your mybboard.ir cookie path to www.mybboard.ir and redirect all non www requests to the www subdomain.

www.mybboard.ir cookies cannot be read by themes.mybboard.ir so you should be all set.

It's kind of a odd hack tho.
Valid de Impala Wrote:suggestion ... set your mybboard.ir cookie path to www.mybboard.ir and redirect all non www requests to the www subdomain.

www.mybboard.ir cookies cannot be read by themes.mybboard.ir so you should be all set.

It's kind of a odd hack tho.
thanks but I thought about it before. we are known as mybboard.ir and we redirect www.mybboard.ir requests to its smaller equivalent.

Some strange thing is: the order of login, is affective! I logged out from first forum and then login into subdomain. everythin's ok. then went to main forum and logged in. everything's ok again! I'm now using both without problem. funny!
right now I temporarily have no problemSmile just waiting for 1.4 and new features... oh yeah