Win主机去掉WordPress链接中的index.php
简介:由于从未使用Win主机搭建Wordpress网站,所以对这方面没有什么研究,今天看到知更鸟的网站有介绍Win主机去掉WordPress链接中的index.php,特别转载过来,希望对Win主机使用Wordpress系统的站长有所帮助。
将以下代码添加到httpd.ini文件中就可以了
[I...
由于从未使用Win主机搭建Wordpress网站,所以对这方面没有什么研究,今天看到知更鸟的网站有介绍Win主机去掉WordPress链接中的index.php,特别转载过来,希望对Win主机使用Wordpress系统的站长有所帮助。
将以下代码添加到httpd.ini文件中就可以了
[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32
# Protect httpd.ini and httpd.parse.errors files
# from accessing through HTTP
# Rules to ensure that normal content gets through
RewriteRule /sitemap.xml /sitemap.xml [L]
RewriteRule /favicon.ico /favicon.ico [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]
将这个httpd.ini文件上传到服务器,然后进入wordpress后台设置下固定链接
链接格式如: %post_id%.html
刷新博客首页,打开文章链接看看链接地址中的index.php是不是消失了。
原文:http://zmingcx.com/wordpress-remove-the-index-php-win-the-host-link.html

这个主题不错。。打算用
很实用哦,谢谢分享了。
多谢多谢,不过最好别用win主机,虽说便宜吧
很少用WIN的主机~~不错还是支持一个~
对,于wordpress index.php页面确实没啥用