WordPress在IIS ISAPI ReWrite下的URL规则
发布时间:2008-07-01 12:09:00
为了便于搜索引擎抓取,俺们可以将wordpress进行静态URL重写、下面是URL ReWrite的规则!
下面是Rewrite规则:(请将下面代码内容存到httpd.ini,然后选择一种”红色部份”的内容填写到wordpress后台自定链接的”永远链接”)
[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32
# Protect httpd.ini and httpd.parse.errors files
# from accessing through HTTP
# # /%year%%monthnum%%day%/%postname%/
RewriteRule /tag/(.*) /index\.php\?tag=$1
RewriteRule /(about|copyright|leebolin)/ /index\.php\?pagename=$1
RewriteRule /category/(.*)/(feed|rdf|rss|rss2|atom)/?$ /wp-feed\.php\?category_name=$1&feed=$2
RewriteRule /category/?(.*)/ /index\.php\?category_name=$1
RewriteRule /author/(.*)/(feed|rdf|rss|rss2|atom)/?$ /wp-feed\.php\?author_name=$1&feed=$2
RewriteRule /author/?(.*) /index\.php\?author_name=$1
RewriteRule /feed/?$ /wp-feed\.php/\?feed=rss2
RewriteRule /comments/feed/?$ /wp-feed\.php/\?feed=comments-rss2
RewriteRule /page/(.*)/ /index\.php\?paged=$1
RewriteRule /([0-9]{4})([0-9]{1,2})([0-9]{1,2})/([^/]+)/?([0-9]+)?/?$ /index\.php\?year=$1&monthnum=$2&day=$3&name=$4&page=$5
RewriteRule /([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$ /index\.php\?year=$1&monthnum=$2&day=$3&page=$4
RewriteRule /([0-9]{4})/([0-9]{1,2})/?$ /index\.php\?year=$1&monthnum=$2&page=$3
RewriteRule /([0-9]{4})([0-9]{1,2})([0-9]{1,2})/([^/]+)/(feed|rdf|rss|rss2|atom)/?$ /index\.php\?year=$1&monthnum=$2&day=$3&name=$4&feed=$5
RewriteRule /([0-9]{4})([0-9]{1,2})([0-9]{1,2})/([^/]+)/trackback/?$ /wp-trackback\.php\?year=$1&monthnum=$2&day=$3&name=$4&tb=1
# # WordPress rewrite rules#
# /Html/%post_id%.html
RewriteRule /tag/(.*) /index\.php\?tag=$1
RewriteRule /(about|copyright|leebolin|favor|archives)/ /index\.php\?
pagename=$1
RewriteRule /Html/category/(.*)/(feed|rdf|rss|rss2|atom)/?$ /wp-feed\.php\?
category_name=$1&feed=$2
RewriteRule /Html/category/?(.*)/ /index\.php\?category_name=$1
RewriteRule /author/(.*)/(feed|rdf|rss|rss2|atom)/?$ /wp-feed\.php\?
author_name=$1&feed=$2
RewriteRule /author/?(.*) /index\.php\?author_name=$1
RewriteRule /rss.xml /wp-feed\.php/\?feed=rss2
RewriteRule /feed/?$ /wp-feed\.php/\?feed=rss2
RewriteRule /comments/feed/?$ /wp-feed\.php/\?feed=comments-rss2
RewriteRule /([0-9]+)/?([0-9]+)?/?$ /index\.php\?p=$1&page=$2
# RewriteRule /Html/([0-9]+)/?([0-9]+)?/?$ /index\.php\?p=$1&page=$2
RewriteRule /Html/([0-9]+).html /index\.php\?p=$1
RewriteRule /page/(.*)/ /index\.php\?paged=$1
RewriteRule /Html/date/([0-9]{4})([0-9]{1,2})([0-9]{1,2})/([^/]+)/?([0-9]+)?/?$
/index\.php\?year=$1&monthnum=$2&day=$3&name=$4&page=$5
RewriteRule /Html/date/([0-9]{4})/([0-9]{1,2})/([0-9]{1,2})/?$ /index\.php\?
year=$1&monthnum=$2&day=$3&page=$4
RewriteRule /Html/date/([0-9]{4})/([0-9]{1,2})/?$ /index\.php\?
year=$1&monthnum=$2&page=$3
RewriteRule /Html/([0-9]+).html/(feed|rdf|rss|rss2|atom)/ /index\.php\?
feed=rss2&p=$1
RewriteRule /Html/([0-9]+).html/trackback/ /wp-trackback\.php\?p=$1
RewriteRule /photo/?([^/]*)?/?([^/]*)?/?([^/]*)?/?([^/]*)?/?$ /wp-
content/plugins/fgallery/fim_photos\.php\?$1=$2&$3=$4 [QSA,L,I]
RewriteRule /photo/?(.*) /wp-content/plugins/fgallery/fim_photos\.php\?
$1=$2&$3=$4 [QSA,L,I]
RewriteRule ^(.*)/archiver/([a-z0-9\-]+\.html)$ $1/archiver/index\.php\?$2
RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html$ $1/forumdisplay\.php\?
fid=$2&page=$3
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ $1/viewthread\.php\?
tid=$2&extra=page\%3D$4&page=$3
RewriteRule ^(.*)/profile-(username|uid)-(.+)\.html$ $1/viewpro\.php\?$2=$3
RewriteCond Host: (.+)
RewriteCond Referer: (?!http://\1.*).*
RewriteRule .*\.(?:gif|jpg|png) /block.gif
RewriteRule ^(.*)/archiver/([a-z0-9\-]+\.html)$ $1/archiver/index\.php\?$2
RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html$ $1/forumdisplay\.php\?fid=$2&page=$3
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ $1/viewthread\.php\?tid=$2&extra=page\%3D$4&page=$3
RewriteRule ^(.*)/profile-(username|uid)-(.+)\.html$ $1/viewpro\.php\?$2=$3
RewriteCond Host: (.+)
RewriteCond Referer: (?!http://\1.*).*
RewriteRule .*\.(?:gif|jpg|png) /block.gif
点这里下载适用于wordpress2.5版本的httpd.ini文件
本站下载地址:httpd.ini.rar (0.69 KB)
猜你喜欢
- 最近在优化韩国留学的网站,在讨论网站关键词时遇到一些技术以外的思维观念问题,拿出来与大家讨论。seoer都知道,优化网站在关键词的选择上是至
- VPS其实和一般的独立Linux服务器,在使用上基本没有区别,因为现在的虚拟化技术以及很成熟了,不过VPS和独服还是有一个很大的差异,那就是
- 当互联网吵吵嚷嚷的进入2.0时代,当互联网的技术不再是那么高不可攀,当复制变成家常便饭,互联网热闹起来了myspace火了,中国冒出更多的m
- 时搁很久的小事了,突然之间又被人提到,大概因为百度马上就要展开的电子商务有关,百度的招商还是比较火热的,在这段时间里,也有不少的商家开始入住
- 微软的WindowsServer2003中防火墙的功能如此之简陋,让很多系统管理员将其视为鸡肋,它一直是一个简单的、仅支持入站防护、基于主机
- 越来越多的开发者与设计者希望将自己的产品开源,以便其他人可以在他们的代码基础上做更多事,开源社区也因此充满生机。在我们所能想到的应用领域,都
- 时下广告联盟遍地都是,大的有GOOGLE BAIDU YAHOO等 小的就不计其数了,现在又推出了重量级的联盟就是 阿里妈妈。面对如此繁多的
- 由于多数是国内空间转国外空间的朋友,所以碰到最多的问题集中在对WHM+cPanel使用上的不了解,而WHM+cPanel的这种集众多功能于一
- Discuz!7.0中,大大增强了论坛防灌水功能。相信很多站长都感受过论坛被疯狂灌水的烦恼,其实,只要巧妙地利用好 Discuz! 后台的各
- SEO=∫Clock=∫C1+L2+K3+O41、∫是一个积分符号,C=content,L=
- 这段时间买国外主机的筒子们越来越多,而付款就是首先摆在大家眼前的一道障碍,大部分美国主机商只能通过信用卡购买,付款不方便,因此能够使用支付宝
- 日前,基于gmail基础上的谷歌微博Buzz正式上线,业界称其为“Twitter杀手,架在facebook颈上的一把刀”。无独有偶,微博的竞
- 网络中纷乱复杂的信息良莠不齐,而少年儿童又有强烈的好奇心,往往在不经意间就点入一些不健康的网站。对此,不少家长都在寻求一些行之有效,又能健康
- 这两天遇到一个很愚蠢的问题,每次登录淘宝/支付宝的时候,总是会遇到“此网站的安全证书有问题”的提示,指出正在访问的网站所出具的安全证书未生效
- 北京时间2008年7月26消息,据国外媒体报道,最近,微软和一些亚洲研究机构一起提出新的搜索引擎Web页面等级排序方法BrowseRank。
- 本文是谷歌关键字广告(Google AdWords)专家Amanda Kelly在“事半功倍做营销”
- 教育娃娃就要从多方面进行,合理引导使用电脑当然是必选方式。如今从网络中真正找到一个绿色健康、又寓教于乐的纯免费工具可真不容易,幸好一直有“花
- 情人节将至,有网络广告界分析人士预计,情人节期间网络广告整体额度将较去年同期上升两成,因众多商家在节后纷纷开张,选择情人节期间进行网络营销势
- 内容代码/templets/system/channel/channel_downlinks.htm文件<script la
- 据国家教育部统计,截至2009年7月1日,我国普通高校毕业生就业率为68%,约有200万毕业生未实现顺利就业。“我们作为