帮助与文档

全部文档
帮助与文档 > 云服务器 > 建站教程 > 常用网站伪静态设置规则

常用网站伪静态设置规则

Discuz X3.2

  1. RewriteEngine On
  2. RewriteBase /
  3. RewriteCond %{QUERY_STRING} ^(.*)$
  4. RewriteRule ^topic-(.+)\.html$ portal.php?mod=topic&topic=$1&%1
  5. RewriteCond %{QUERY_STRING} ^(.*)$
  6. RewriteRule ^article-([0-9]+)-([0-9]+)\.html$ portal.php?mod=view&aid=$1&page=$2&%1
  7. RewriteCond %{QUERY_STRING} ^(.*)$
  8. RewriteRule ^forum-(\w+)-([0-9]+)\.html$ forum.php?mod=forumdisplay&fid=$1&page=$2&%1
  9. RewriteCond %{QUERY_STRING} ^(.*)$
  10. RewriteRule ^thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ forum.php?mod=viewthread&tid=$1&extra=page\%3D$3&page=$2&%1
  11. RewriteCond %{QUERY_STRING} ^(.*)$
  12. RewriteRule ^group-([0-9]+)-([0-9]+)\.html$ forum.php?mod=group&fid=$1&page=$2&%1
  13. RewriteCond %{QUERY_STRING} ^(.*)$
  14. RewriteRule ^space-(username|uid)-(.+)\.html$ home.php?mod=space&$1=$2&%1
  15. RewriteCond %{QUERY_STRING} ^(.*)$
  16. RewriteRule ^blog-([0-9]+)-([0-9]+)\.html$ home.php?mod=space&uid=$1&do=blog&id=$2&%1
  17. RewriteCond %{QUERY_STRING} ^(.*)$
  18. RewriteRule ^archiver/(fid|tid)-([0-9]+)\.html$ archiver/index.php?action=$1&value=$2&%1
  19. RewriteCond %{QUERY_STRING} ^(.*)$
  20. RewriteRule ^([a-z]+[a-z0-9_]*)-([a-z0-9_\-]+)\.html$ plugin.php?id=$1:$2&%1

Wordpress

  1. RewriteEngine On
  2. RewriteBase /
  3. RewriteRule ^index\.php$ - [L]
  4. RewriteCond %{REQUEST_FILENAME} !-f
  5. RewriteCond %{REQUEST_FILENAME} !-d
  6. RewriteRule . /index.php [L]

Typecho

  1. RewriteEngine On
  2. RewriteBase /
  3. RewriteCond %{REQUEST_FILENAME} !-f
  4. RewriteCond %{REQUEST_FILENAME} !-d
  5. RewriteRule ^(.*)$ /index.php/$1 [L]

如果在操作过程有任何疑问,请及时提交工单,谢谢!

这条帮助是否解决了您的问题? 已解决 未解决

提交成功!非常感谢您的反馈,我们会继续努力做到更好!更多建议 非常抱歉未能帮助到您。为了给您提供更好的服务,我们很需要您进一步的反馈信息:

在文档使用中是否遇到以下问题:

更多建议