开发者

opencart cookies problem - how to fix?

开发者 https://www.devze.com 2023-03-07 01:17 出处:网络
i have 2 stores here : oc v1.4.9.3 1) tsubamecorp.com/singapore/ 2) tsubamecorp.com/malaysia/ The problem is when you login to tsubamecorp.com/singapore/admin everything is work fine.

i have 2 stores here : oc v1.4.9.3

1) tsubamecorp.com/singapore/
2) tsubamecorp.com/malaysia/

The problem is when you login to tsubamecorp.com/singapore/admin everything is work fine.

The url after login look something like this

tsubamecorp.com/singapore/admin/index.php?route=common/home&token=827bcf36d9c167581620f377417e8774
but when you change the folder from singapore to malaysia in url
tsubamecorp.com/malaysia/admin/index.php?route=common/home&token=827bcf36d9c167581620f377417e8774
you can login without put username or pass in login page for malaysia store!!!

This only happen when you try in same browser.

Any solutions开发者_如何学JAVA??


Without changing the default behaviour of OpenCart (as explained by Zappo) you should set up a new host name for each shop instead. You'll have to register two separate DNS names and then access your shops as follows...

malaysia.tsubamecorp.com/admin/index.php
singapore.tsubamecorp.com/admin/index.php

You can still run with a single installation of OpenCart and a single database. This post may help you understand this configuration better...

http://forum.opencart.com/viewtopic.php?f=20&t=21411


I think this will only occur when you change the name and refresh. I guess when you log out and try to login again it will no work.


That's default OpenCart behaviour... I also think Jerome is correct. The cookies are in the same domain, so OpenCart thinks you're still logged-in.

HOWEVER, I don't see your problem... If someone is able to get that cookie set, he or she already logged in... (e.g. This can not happen when someone did not log in)

0

精彩评论

暂无评论...
验证码 换一张
取 消