【问题标题】:Wordpress url shows page not found on localhost, but online its fineWordpress url 显示在 localhost 上找不到的页面,但在网上很好
【发布时间】:2011-06-03 22:51:53
【问题描述】:

我已经安装了wordpress,现在http://localhost/wp-login.php之类的都可以了。假设我想转到诸如 http://localhost/something-here/ 之类的页面,则会出现 404 错误。此 404 错误仅发生在 localhost 上,而不发生在实时服务器上。

这是什么原因。

谢谢 让

【问题讨论】:

  • 你在本地服务器上启用了 mod_rewrite 吗?
  • 嗯,假设没有,因为我的时间不多,我该如何启用它,我正在使用 wamp
  • mod_rewrite.so 在 httpd.conf 中启用
  • 我将永久链接更改为 ?id=14

标签: wordpress httpd.conf hosts-file


【解决方案1】:

尝试刷新您的 URL:转到 设置永久链接更新

【讨论】:

  • 刷新不起作用,它在 php.ini 或 httpd.conf 中的一些设置
【解决方案2】:

WAMP 中,您可以转至 WAMP icon in the system tray > Apache > Apache Modules > Tick the rewrite_module

【讨论】:

    【解决方案3】:

    如果您使用的是 wamp,请单击 wamp 图标并:Apache > Apache Modules > 确保勾选了 rewrite_module。

    【讨论】:

    • rewrite_module 未注释
    【解决方案4】:

    按照以下步骤操作 1. URL:进入设置→永久链接设置→通用设置 2.选择本地服务器的默认url格式

    【讨论】:

      猜你喜欢
      • 2018-02-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-09-16
      • 1970-01-01
      • 1970-01-01
      • 2015-06-02
      • 1970-01-01
      相关资源
      最近更新 更多