bo-blog 在IIS服务器中实现URL Rewrite - IDC资讯网_站长学院 - Java PHP Flex Python Ajax CSS 编程 开源 学习 总结 分享
[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32

RewriteRule ^(.*)/post/([0-9]+)/?([0-9]+)?/?([0-9]+)?/?$ $1/read\.php\?entryid=$2&page=$3&part=$4
RewriteRule ^(.*)/page/([0-9]+)/([0-9]+)/?$ $1/index\.php\?mode=$2&page=$3
RewriteRule ^(.*)/starred/([0-9]+)/?([0-9]+)?/?$ $1/star.php\?mode=$2&page=$3
RewriteRule ^(.*)/category/([^/]+)/?([0-9]+)?/?([0-9]+)?/?$ $1/index\.php\?go=category_$2&mode=$3&page=$4
RewriteRule ^(.*)/archiver/([0-9]+)/([0-9]+)/?([0-9]+)?/?([0-9]+)?/?$ $1/index\.php\?go=archive&cm=$2&cy=$3&mode=$4&page=$5
RewriteRule ^(.*)/date/([0-9]+)/([0-9]+)/([0-9]+)/?([0-9]+)?/?([0-9]+)?/?$ $1/index\.php\?go=showday_$2-$3-$4&mode=$5&page=$6
RewriteRule ^(.*)/user/([0-9]+)/?$ $1/view\.php\?go=user_$2
RewriteRule ^(.*)/tags/([^/]+)/?([0-9]+)?/?([0-9]+)?/?$ $1/tag\.php\?tag=$2&mode=$3&page=$4
RewriteRule ^(.*)/component/id/([0-9]+)/?$ $1/page\.php\?pageid=$2
RewriteRule ^(.*)/component/([^/]+)/?$ $1/page\.php\?pagealias=$2

RewriteRule ^(.*)/post/([0-9]+)\.htm$ $1/post/$2/ [NC,R=301]
RewriteRule ^(.*)/post/([0-9]+)\_([0-9]+)\.htm$ $1/post/$2/$3/ [NC,R=301]
RewriteRule ^(.*)/post/([0-9]+)\_([0-9]+)\_([0-9]+)\.htm$ $1/post/$2/$3/$4/ [NC,R=301]
RewriteRule ^(.*)/index\_([0-9]+)\_([0-9]+)\.htm$ $1/page/$2/$3/ [NC,R=301]
RewriteRule ^(.*)/star\_([0-9]+)\_([0-9]+)\.htm$ $1/starred/$2/$3/ [NC,R=301]
RewriteRule ^(.*)/category\_([0-9]+)\.htm$ $1/category/$2/ [NC,R=301]
RewriteRule ^(.*)/category\_([0-9]+)\_([0-9]+)\_([0-9]+)\.htm$ $1/category/$2/$3/$4/ [NC,R=301]
RewriteRule ^(.*)/archive\_([0-9]+)\_([0-9]+)\.htm$ $1/archiver/$2/$3/ [NC,R=301]
RewriteRule ^(.*)/archive\_([0-9]+)\_([0-9]+)\_([0-9]+)\_([0-9]+)\.htm$ $1/archiver/$2/$3/$4/$5/ [NC,R=301]
RewriteRule ^(.*)/showday\_([0-9]+)\_([0-9]+)\_([0-9]+)\.htm$ $1/date/$2/$3/$4/ [NC,R=301]
RewriteRule ^(.*)/showday\_([0-9]+)\_([0-9]+)\_([0-9]+)\_([0-9]+)\_([0-9]+)\.htm$ $1/date/$2/$3/$4/$5/$6/ [NC,R=301]

RewriteRule ^(.*)/([^\/]*)\.html$ $1/$2/ [NC,R=301]
RewriteRule ^(.*)/([^/|.]*)/?([0-9]+)?/?([0-9]+)?/?$ $1/read\.php\?blogalias=$2&page=$3&part=$4  [QSA,L,I]

工具&软件 | 评论(0) | 引用(0) | 阅读(3697)