dongyinzheng6572 2014-09-09 09:47
浏览 139
已采纳

Localhost - 您的浏览器阻止或不支持Cookie

I just set up this multisite wordpress on my localhost. It consists of a domain (local.mydomain.com) and 2 subdomains (local.site2.mydomain.com and local.site3.mydomain.com).

Everything works perfectly for the root domain, I can log in and go to the backend just fine, but when I try to log into any of the subdomains I get the "Cookies are blocked or not supported by your browser." error.

  • Yes, my cookies are enabled.
  • I tried the wp-config define hack
  • Cleared cache
  • Disabled plugins and themes
  • Updated to 4.0

I realize this has been posted many times before, but I haven't seen a recent post for this nor I have seen the multisite in localhost version of that error.

Hopefully someone can help me out. Cheers!

  • 写回答

1条回答 默认 最新

  • drz5553 2015-10-09 11:07
    关注

    You said "I tried the wp-config" define hack. I'm not sure what you mean by that but in my case it worked by setting the one below in the wp-config.php file:

    define('COOKIE_DOMAIN', false);

    One the other hand, if you are using Apache as a web server then check in your Apache configuration if you have enabled mod_security turned ON. This will prevent, among others, the cookie thing. So if it is enabled then just try to disable this module and check again. If it is the cause of the problem then check its configuration, particularly any settings related to cookies.

    The settings for this Apache module may be stored within a file named modsecurity.conf. They may be found even in Apache's httpd.conf as well. You got the idea, anyway.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥35 平滑拟合曲线该如何生成
  • ¥100 c语言,请帮蒟蒻写一个题的范例作参考
  • ¥15 名为“Product”的列已属于此 DataTable
  • ¥15 安卓adb backup备份应用数据失败
  • ¥15 eclipse运行项目时遇到的问题
  • ¥15 关于#c##的问题:最近需要用CAT工具Trados进行一些开发
  • ¥15 南大pa1 小游戏没有界面,并且报了如下错误,尝试过换显卡驱动,但是好像不行
  • ¥15 自己瞎改改,结果现在又运行不了了
  • ¥15 链式存储应该如何解决
  • ¥15 没有证书,nginx怎么反向代理到只能接受https的公网网站