Discuz!官方免费开源建站系统

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索

[已解决] dvbbs=>Discuz! X2.5保持搜索引擎带来的流量之rewrite 规则

[复制链接]
白乐天 发表于 2013-2-7 13:15:37 | 显示全部楼层 |阅读模式
本帖最后由 白乐天 于 2013-2-7 13:20 编辑

以前的版本太古旧了,现在新写了一份跟大家分享。将下列内容保存为httpd.ini,或者直接下载附件包即可。此规则IIS适用,apache用户可据此自行修改。


[ISAPI_Rewrite]

# 3600 = 1 hour
CacheClockRate 3600

RepeatLimit 32

# Protect httpd.ini and httpd.parse.errors files
# from accessing through HTTP

RewriteRule ^(.*)/index\.asp\?[bB]oard[iI][dD]=(\d+)$ $1/forum\.php\?mod=forumdisplay&fid=$2
RewriteRule ^(.*)/dispbbs\.asp\?[bB]oard[iI][dD]=(\d+)&[iI][dD]=(\d+)$ $1/forum\.php\?mod=viewthread&tid=$3
RewriteRule ^(.*)/index\.asp\?[bB]oard[iI][dD]=(\d+)&[pP]age=(\d+)$ $1/forum\.php\?mod=forumdisplay&fid=$2&page=$3
RewriteRule ^(.*)/dispbbs\.asp\?[bB]oard[iI][dD]=(\d+)&[iI][dD]=(\d+)&page=(\d+)$ $1/forum\.php\?mod=viewthread&tid=$3&page=$4
RewriteRule ^(.*)/dispbbs\.asp\?[bB]oard[iI][dD]=(\d+)&[iI][dD]=(\d+)&authorid=(\d+)$ $1/forum\.php\?mod=viewthread&tid=$3&page=1&authorid=$4
RewriteRule ^(.*)/dispbbs\.asp\?[bB]oard[iI][dD]=(\d+)&[iI][dD]=(\d+)&authorid=(\d+)&page=(\d+)&star=(\d+)$ $1/forum\.php\?mod=viewthread&tid=$3&page=$6
RewriteRule ^(.*)/topic-(.+)\.html(\?(.*))*$ $1/portal\.php\?mod=topic&topic=$2&$4
RewriteRule ^(.*)/article-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/portal\.php\?mod=view&aid=$2&page=$3&$5
RewriteRule ^(.*)/forum-(\w+)-([0-9]+)\.html(\?(.*))*$ $1/forum\.php\?mod=forumdisplay&fid=$2&page=$3&$5
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/forum\.php\?mod=viewthread&tid=$2&extra=page\%3D$4&page=$3&$6
RewriteRule ^(.*)/group-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/forum\.php\?mod=group&fid=$2&page=$3&$5
RewriteRule ^(.*)/space-(username|uid)-(.+)\.html(\?(.*))*$ $1/home\.php\?mod=space&$2=$3&$5
RewriteRule ^(.*)/blog-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/home\.php\?mod=space&uid=$2&do=blog&id=$3&$5
RewriteRule ^(.*)/(fid|tid)-([0-9]+)\.html(\?(.*))*$ $1/index\.php\?action=$2&value=$3&$5
RewriteRule ^(.*)/([a-z]+[a-z0-9_]*)-([a-z0-9_\-]+)\.html(\?(.*))*$ $1/plugin\.php\?id=$2:$3&$5





本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x

评分

1

查看全部评分

12153556 发表于 2013-2-7 13:20:29 | 显示全部楼层
支持,以前我发布过一个,但是没有你这个完整
回复

使用道具 举报

 楼主| 白乐天 发表于 2013-2-7 13:25:38 | 显示全部楼层
12153556 发表于 2013-2-7 13:20
支持,以前我发布过一个,但是没有你这个完整

谢谢支持,昨晚找来找去找到一个dz4.1时期的,没找到你发的版本。
https://discuz.dismall.com/thread-488300-1-1.html

已经不适用了,索性改写一份新版的发上来大家试试。
回复

使用道具 举报

baxter 发表于 2013-2-7 13:41:03 | 显示全部楼层
本帖最后由 baxter 于 2013-2-7 13:50 编辑

支持一下  谢谢分享 {:soso_e100:}
回复

使用道具 举报

欢迎您光临 发表于 2013-2-7 17:19:53 | 显示全部楼层
帮顶。。。。。
回复

使用道具 举报

stzgd 发表于 2013-2-21 12:53:37 | 显示全部楼层
多谢分享了nh
回复

使用道具 举报

zouyan198429 发表于 2013-2-21 13:25:16 | 显示全部楼层
多谢分享了
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2024-9-28 01:18 , Processed in 0.299838 second(s), 19 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表