V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
a852022
V2EX  ›  问与答

请教各位大侠一个关于 wordpress 的问题

  •  
  •   a852022 · 2018-01-21 19:16:59 +08:00 · 653 次点击
    这是一个创建于 2452 天前的主题,其中的信息可能已经有所发展或是发生改变。

    我的网站是用伪静态的,然后别的都正常就是分类目录和标签点进去然后按下一页就 404,但是很奇怪我首页点进去按下一页又是正常的,首页他也是后面加 /的都正常,我看了一下就是我分类目录和标签页点进去按下一页他是这样的 category/tlxw/page/3/他就 404.如果我把 3 后面的斜杠去掉 category/tlxw/page/3 这样子他又能正常显示第 3 页,默认是多一条斜杠他就显示 404,求大侠帮帮我小白刚接触不太懂啊不知道跟伪静态有没有关系谢谢了 下面这个就是我伪静态。我用的是 /%post_id%.html

    3600 = 1 hour

    CacheClockRate 3600 RepeatLimit 32

    Protect httpd.ini and httpd.parse.errors files

    from accessing through HTTP

    wordpress 伪静态规则

    For tag (中文标签以及标签翻页的规则)

    RewriteRule /tag/(.*)/page/(\d+)$ /index.php?tag=$1&paged=$2 RewriteRule /tag/(.+)$ /index.php?tag=$1

    For category (中文分类以及分类翻页的规则)

    RewriteRule /category/(.)/page/(\d+)$ ?category_name=$1&paged=$2 RewriteRule /category/(.) ?category_name=$1

    For sitemapxml

    RewriteRule /sitemap.xml /sitemap.xml [L] RewriteRule /favicon.ico /favicon.ico [L] RewriteRule /shenma-site-verification.txt /shenma-site-verification.txt [L] RewriteRule /10a7fca63634c1968e024906b3790978.txt /10a7fca63634c1968e024906b3790978.txt [L] RewriteRule /baidu_verify_HHNFDuXzMv.html /baidu_verify_HHNFDuXzMv.html [L] RewriteRule /sogousiteverification.txt /sogousiteverification.txt [L]

    For file-based wordpress content (i.e. theme), admin, etc.

    RewriteRule /wp-(.*) /wp-$1 [L]

    For normal wordpress content, via index.php

    RewriteRule ^/$ /index.php [L] RewriteRule /(.) /index.php/$1 [L] RewriteRule /index.php/(.) /index.php/$1 [L]

    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   3809 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 22ms · UTC 10:23 · PVG 18:23 · LAX 03:23 · JFK 06:23
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.