dsh8009271 2015-07-26 19:22
浏览 35
已采纳

子域名的Magento cookie设置

When I am installing Magento under a subdomain of my production domain, I cannot login to magento admin. For example, my domain name is example.com where I have installed magento and it is in production, I am ok with admin login.

However, I have a subdomain called test.example.com and I installed magento there for testing purpose. Now, if I try to login to the test site, I can't login. The username and passwords are correct. I see no error message. It just reloads the same login page. Same things happens when I try to login to my production site admin panel.

If I clear the cookies related to example.com and test.example.com and then try to login to the admin panel of example.com, I am fine. Now, when I try to login to test.example.com admin panel, the problem starts again.

This is what my Session Cookie management settings

Is there anybody who can help me solving this issue?

  • 写回答

2条回答 默认 最新

  • doudou20145 2015-07-26 21:03
    关注

    Your live system's cookie are set for .example.com, which means for your live system's domain and also all subdomains. Because test.example.com is a subdomain, both cookies are valid for it.

    Try the following settings, then Magento will set cookies for .www.example.com and .test.example.com and your live domain's cookies will not interfere with your subdomain's.

    live domain

    subdomain

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 树莓派与pix飞控通信
  • ¥15 自动转发微信群信息到另外一个微信群
  • ¥15 outlook无法配置成功
  • ¥30 这是哪个作者做的宝宝起名网站
  • ¥60 版本过低apk如何修改可以兼容新的安卓系统
  • ¥25 由IPR导致的DRIVER_POWER_STATE_FAILURE蓝屏
  • ¥50 有数据,怎么建立模型求影响全要素生产率的因素
  • ¥50 有数据,怎么用matlab求全要素生产率
  • ¥15 TI的insta-spin例程
  • ¥15 完成下列问题完成下列问题