最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
dedecms 开启伪静态配置方法
时间:2022-06-25 16:40:26 编辑:袖梨 来源:一聚教程网
如果是Apache的服务器,就在.htaccess里面写上
| 代码如下 | 复制代码 |
|
RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule index.html /index.php RewriteRule plus/list-([0-9]+).html$ /plus/list.php?tid=$1 RewriteRule plus/view-([0-9]+)-([0-9]+).html$ /plus/view.php?arcID=$1&pageno=$3 RewriteRule plus/list-([0-9]+)-([0-9]+)-([0-9]+).html$ /plus/list.php?tid=$1&totalresult=$2&PageNo=$3 |
|
IIS的服务器,在httpd.ini里面写上,前提是要服务器安装过ISAPI Rewrite
[ISAPI_Rewrite]
# 缓存3600秒 = 1 小时(hour)
| 代码如下 | 复制代码 |
|
CacheClockRate 3600 RepeatLimit 32 RewriteRule ^(.*)/index.html $1/index.php RewriteRule ^(.*)/plus/list-([0-9]+).html $1/plus/list.php?tid=$2 RewriteRule ^(.*)/plus/list-([0-9]+)-([0-9]+)-([0-9]+).html $1/plus/list.php?tid=$2&TotalResult=$3&PageNo=$4 RewriteRule ^(.*)/plus/view-([0-9]+)-([0-9]+).html $1/plus/view.php?arcID=$2&pageno=$3 |
|
然后我们修改dedecms的程序,打开includechannelunit.func.php
| 代码如下 | 复制代码 |
| $reurl = $GLOBALS['cfg_phpurl']."/list.php?tid=".$typeid; | |
替换为
| 代码如下 | 复制代码 |
| $reurl = $GLOBALS['cfg_phpurl']."/list-".$typeid.".html"; | |
相关文章
- 嘟嘟传奇嘟嘟之恋任务攻略 03-21
- 《元启世界》法师玩法攻略 03-21
- 耐玩的角色扮演类网络游戏推荐哪些 2026高人气的角色扮演手游下载分享 03-21
- 三角洲行动航天基地每日密码3月20日-航天基地3月20日密码 03-21
- 热门的像素射击游戏排行榜前五推荐 2026值得下载的像素射击游戏汇总 03-21
- 《生存33天》联盟对决玩法介绍 03-21