【问题标题】:404 error after delete index.php in permalinks wordpress在永久链接 wordpress 中删除 index.php 后出现 404 错误
【发布时间】:2019-06-19 02:34:49
【问题描述】:

我想更改我的 WordPress 博客中的永久链接。我选择了/%category%/%postname%/。更改后,我收到 404 错误。如果我添加 /index.php/%category%/%postname%/ 效果很好,但是,我不需要这样的链接。我的 .htaccess 是

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress

我检查了我的 httpd.conf 并添加了这样的行 LoadModule rewrite_module modules/mod_rewrite.so

在我的 wordpress 链接中没有 indes.php,它仍然无法工作

【问题讨论】:

    标签: wordpress .htaccess http-status-code-404 httpd.conf permalinks


    【解决方案1】:

    不要编辑 .htaccess 文件,在 WordPress 中转到后端设置 -> 永久链接页面,您可以在其中管理此设置。查看截图:

    【讨论】:

    • 我也有。
    猜你喜欢
    • 1970-01-01
    • 2011-05-22
    • 2021-10-03
    • 2016-01-16
    • 1970-01-01
    • 1970-01-01
    • 2016-07-19
    • 2018-04-23
    • 1970-01-01
    相关资源
    最近更新 更多