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

 找回密码
 立即注册
搜索

[转换] discuz!nt转换后Rewrite保流量,求解。

[复制链接]
yafeiml 发表于 2007-8-18 05:18:44 | 显示全部楼层 |阅读模式
前几天从discuz!nt转换到了discuz!php,做了个404页面让以前的连接跳转到了首页,今天想到应该可以用Rewrite来实现这个问题吧,其实就是把DPHP的URL同时Rewrite成showforum-8.aspx这样的连接,请各位高手帮忙了。
论坛收录URL如下:
showforum-8.aspx
showtopic-524.aspx


DISCUZ!NT规则
showforum  /showforum-{0}-{1}.html /showforum-(\d+)(-(\d+))?.aspx /showforum.aspx forumid=$1^page=$3
showtopic  /showtopic-{0}-{1}.html /showtopic-(\d+)(-(\d+))?.aspx /showtopic.aspx topicid=$1^page=$3
userinfo  /userinfo-{0}.html /userinfo-(\d+)*.aspx /userinfo.aspx userid=$1
rss  /rss-{0}.aspx /rss(-(\d+))?.aspx /rss.aspx forumid=$2


目前PHP论坛所使用的规则
[ISAPI_Rewrite]
       
        # 3600 = 1 hour
        CacheClockRate 3600
       
        RepeatLimit 32
       
        # Protect httpd.ini and httpd.parse.errors files
        # from accessing through HTTP
        RewriteRule ^(.*)/archiver/([a-z0-9\-]+\.html)\?*(.*)$ $1/archiver/index\.php\?$2&$3
        RewriteRule ^(.*)/forum-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/forumdisplay\.php\?fid=$2&page=$3&$4
        RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$ $1/viewthread\.php\?tid=$2&extra=page\%3D$4&page=$3&$4
        RewriteRule ^(.*)/profile-(username|uid)-(.+)\.html\?*(.*)$ $1/viewpro\.php\?$2=$3&$4
        RewriteRule ^(.*)/space-(username|uid)-(.+)\.html\?*(.*)$ $1/space\.php\?$2=$3&$4

[ 本帖最后由 yafeiml 于 2007-8-18 05:34 编辑 ]
回复

使用道具 举报

 楼主| yafeiml 发表于 2007-8-18 08:48:19 | 显示全部楼层
自己挺一下。。。。。。。。。
回复

使用道具 举报

suchaozheng 发表于 2007-8-18 12:50:30 | 显示全部楼层
回复

使用道具 举报

Talentdj 发表于 2007-8-18 17:25:15 | 显示全部楼层
请问楼主怎么转到,有转换插件吗,我也急需要转,谢谢!:)
回复

使用道具 举报

 楼主| yafeiml 发表于 2007-8-18 20:50:11 | 显示全部楼层
挺到高手来。:)
回复

使用道具 举报

ght0124 发表于 2007-8-20 02:07:16 | 显示全部楼层
这个得找正则式高手。。
回复

使用道具 举报

 楼主| yafeiml 发表于 2007-8-22 13:50:29 | 显示全部楼层
来个高人吧,谢谢。。。。。。。。。。
回复

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-9-13 07:50 , Processed in 0.084051 second(s), 14 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

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