您现在的位置是:首页 > cms教程 > DedeCMS教程DedeCMS教程
织梦dx tipask dedeask静态规则及二级栏目301重定向方法
依珊2023-10-03DedeCMS教程已有人查阅
导读# 二级栏目301重定向到二级域名方法,如将http://www.ebingou.cn/bbs/重定向http://bbs.ebingou.cn
# 二级栏目301重定向到二级域名方法,如将http://www.ebingou.cn/bbs/重定向http://bbs.ebingou.cn
RewriteCond %{http_host} ^ebingou.cn [NC]
RewriteRule ^(.*)$ http://www.ebingou.cn/$1 [L,R=301]
# Protect httpd.ini and httpd.parse.errors files
# from accessing through HTTP
RewriteRule ^(.*)/bbs/(.*)$ $1/bbs/301\.php\?go=$2 [L]
# 301.php文件内容
<?php
$go=$_GET['go'];//获取跳转页面链接部分,如"thread-112-1.html",又如forum.php?fid=32等
header("HTTP/1.1 301 Moved Permanently");//发送301状态,之后的所有跳转均为301
header('location:http://bbs.ebingou.cn/'.
# tipask静态规则
allow_url_fopen = On
RewriteRule ^(.*)/c-([0-9]+)\.html$ $1/index\.php\?category/view/$2.html
RewriteRule ^(.*)/l-([0-9]+)\.html$ $1/index\.php\?category/list/$2.html
RewriteRule ^(.*)/r-([0-9]+)\.html$ $1/index\.php\?category/recommend/$2.html
RewriteRule ^(.*)/q-([0-9]+)\.html$ $1/index\.php\?question/view/$2.html
RewriteRule ^(.*)/u-([0-9]+)\.html$ $1/index\.php\?user/space/$2.html
RewriteRule ^(.*)/us-([0-9]+)\.html$ $1/index\.php\?user/scorelist/$2.html
RewriteRule ^(.*)/c-([0-9]+)/([0-9]+)\.html$ $1/index\.php\?c-$2/$3.html
RewriteRule ^(.*)/c-([0-9]+)/all/([0-9]+)\.html$ $1/index\.php\?c-$2/all/$3.html
RewriteRule ^(.*)/c-([0-9]+)/all\.html$ $1/index\.php\?c-$2/all\.html
RewriteRule ^(.*)/c-([0-9]+)/([0-9]+)/([0-9]+)\.html$ $1/index\.php\?c-$2/$3/$4.html
RewriteRule ^(.*)/c-([0-9]+)/([0-9]+)\.html$ $1/index\.php\?c-$2/$3.html
RewriteRule ^(.*)/l-([0-9]+)/([0-9]+)\.html$ $1/index\.php\?l-$2/$3.html
RewriteRule ^(.*)/u-([0-9]+)\.html$ $1/index\.php\?u-$2.html
RewriteRule ^(.*)/r-([0-9]+)\.html$ $1/index\.php\?r-$2.html
RewriteRule ^(.*)/gift\.html$ $1/index\.php\?gift.html
RewriteRule ^(.*)/user/ask\.html$ $1/index\.php\?user/ask.html
RewriteRule ^(.*)/user/answer\.html$ $1/index\.php\?user/answer.html
RewriteRule ^(.*)/user/favorite\.html$ $1/index\.php\?user/favorite.html
RewriteRule ^(.*)/message/new\.html$ $1/index\.php\?message/new.html
RewriteRule ^(.*)/user/score\.html$ $1/index\.php\?user/score.html
RewriteRule ^(.*)/question/add\.html$ $1/index\.php\?question/add.html
RewriteRule /ask/([a-z,0-9]*)-([a-z,0-9]*)-([0-9]+)\.html /ask/$1.php?$2=$3
RewriteRule ^(.*)/question-id-([0-9]+)\.html$ $1/question\.php\?id=$2
RewriteRule ^(.*)/browser-tid-([0-9]+)\.html$ $1/browser\.php\?tid=$2
RewriteRule ^(.*)/browser-tid2-([0-9]+)\.html$ $1/browser\.php\?tid2=$2
RewriteRule ^(.*)/browser-lm-([0-9]+)\.html$ $1/browser\.php\?lm=$2
RewriteRule ^(.*)/browser-tid-([0-9]+)-lm-([0-9]+)\.html$ $1/browser\.php\?tid=$2&lm=$3
RewriteRule ^(.*)/browser-tid2-([0-9]+)-lm-([0-9]+)\.html$ $1/browser\.php\?tid2=$2&lm=$3
#DX2.0静态规则
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/topic-(.+)\.html$ $1/portal.php?mod=topic&topic=$2&%1
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/article-([0-9]+)-([0-9]+)\.html$ $1/portal.php?mod=view&aid=$2&page=$3&%1
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/forum-(\w+)-([0-9]+)\.html$ $1/forum.php?mod=forumdisplay&fid=$2&page=$3&%1
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$ $1/forum.php?mod=viewthread&tid=$2&extra=page\%3D$4&page=$3&%1
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/group-([0-9]+)-([0-9]+)\.html$ $1/forum.php?mod=group&fid=$2&page=$3&%1
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/space-(username|uid)-(.+)\.html$ $1/home.php?mod=space&$2=$3&%1
RewriteCond %{QUERY_STRING} ^(.*)$
RewriteRule ^(.*)/([a-z]+)-(.+)\.html$ $1/$2.php?rewrite=$3&%1
</IfModule>
本文标签:
很赞哦! ()
相关教程
- 织梦cms、帝国cms、PHPcms优缺点分析
- PHPCMS和织梦DEDECMS对比分析
- 织梦、phpcms程序添加ftp://、thunder://、flashget:文件下载时
- 织梦cms和PHPcms及帝国cms比较,哪个好?
- 织梦模板怎么套PHPCMS
- PHPCMS与织梦CMS有什么区别呢
- 10个常用的eyoucms易优CMS标签(织梦CMS迁移可用)的方法
- 织梦cms收费哪几款cms可以免费商用?
- dedecms织梦发布内容网站为空白的原因有哪些
- dedecms织梦程序安装后无法修改栏目的解决方法
- 织梦标签{global.cfg_templets_skin}不解析地址的解决方法
- 织梦导航栏栏目被选中状态的代码实例
图文教程
dedecms自定义表单列表编辑内容联动地区显示为数字的方法
解决方法;打开 \dede\templets\diy_edit_content.htm 找到这一块PHP代码改成
dedecms网站地图生成目录的修改方法
使用过DEDECMS的站长朋友都知道,DEDECMS默认生成的rss地图以及网站地图等都是生成在DATA的文件夹中,但是这个是一个非常重要的文件夹
dedecms默认模板文件夹templets各个文件的作用介绍
在织梦(DedeCMS)系统中,所有的模板存放形式均是以文件的形式存放在系统模板目录(templets)下的默认模板风格目录里。
织梦系统$GLOBALS定义文件位置函数介绍
DedeCMS数据库的信息是写在data/common.inc.php,而系统连接数据库时使用的有一个函数是:
相关源码
-
(自适应)html5中英双语通用机械设备pbootcms模板下载本模板基于PbootCMS内核精心开发,为机械设备制造企业量身打造。设计风格大气稳重,充分展现机械行业的专业特质与技术实力。采用HTML5技术构建,支持中英文双语切换,满足国际化业务需求。整站布局合理,充分展示企业产品、案例与服务,帮助访客快速了解企业核心优势。查看源码 -
(自适应响应式)高新技术科技能源pbootcms网站HTML5模板本模板基于PbootCMS内核开发,为高新技术、科技研发、能源技术等科技型企业设计。采用HTML5+CSS3前沿技术,具备完善的响应式布局,能够自动适配手机、平板和电脑等多种终端设备。模板设计风格简约大气查看源码 -
自适应LED照明外贸灯具灯泡灯具英文网站模板该外贸灯具网站模板专为LED照明、灯具出口企业定制,采用PbootCMS内核开发,提供高效建站方案。通过响应式设计和SEO优化能力,帮助企业低成本构建专业外贸展示平台。查看源码 -
(PC+WAP)盆栽绿植观赏植物花卉租赁免费pbootcms网站模板为花卉盆栽租赁、园林绿化企业打造的PbootCMS网站模板,采用较新内核开发,PC与移动端数据实时同步。通过清新自然的视觉设计,精准展现植物养护、花卉展示等业务场景,帮助用户快速建立专业级行业网站。查看源码 -
(带手机版)绿色生态农业种植农产品网站pbootcms源码下载本模板基于PbootCMS内核开发,为生态农业企业量身打造,适用于农业种植、有机农场、农产品电商等业务场景。模板设计充分体现绿色环保理念,突出农业特色,同时保持简洁大气的视觉效果,帮助农业企业建立专业形象。查看源码 -
(自适应)绿色园林建筑花卉园艺艺术模板免费下载为景观设计及园艺企业打造的响应式网站框架,基于PbootCMS系统开发,帮助传统园林行业建立现代化数字展示平台。采用标准DIV+CSS前端架构,代码精简无冗余。查看源码
| 分享笔记 (共有 篇笔记) |
