destoon采集论坛

 找回密码
 立即注册
查看: 1083|回复: 0

V6.0手机版伪静态不生效,提示Error Loading

[复制链接]

198

主题

91

回帖

2918

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
2918
发表于 2017-4-8 14:30:21 | 显示全部楼层 |阅读模式
经过测试,受不同服务器软件版本、是否绑定二级域名等因素影响,不同服务器对规则的解析存在差异。

以下为各服务器伪静态规则的两种写法,如果第一条写法不生效,试试第二条写法。

通常情况,第一种写法适合不绑定二级域名,第二种写法适合绑定二级域名。

手机版本属于特殊的独立站点,建议有条件的用户尽量绑定二级域名。

Apache

  • RewriteRule ^(.*)/([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html$ $1/index.php?moduleid=$2&catid=$3&itemid=$4&page=$5

[color=rgb(51, 102, 153) !important]复制代码

  • RewriteRule ^([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html$ index.php?moduleid=$1&catid=$2&itemid=$3&page=$4

[color=rgb(51, 102, 153) !important]复制代码



Nginx

  • rewrite ^/(.*)/([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html$ /$1/index.php?moduleid=$2&catid=$3&itemid=$4&page=$5 last;

[color=rgb(51, 102, 153) !important]复制代码

  • rewrite ^/([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html$ /index.php?moduleid=$1&catid=$2&itemid=$3&page=$4 last;

[color=rgb(51, 102, 153) !important]复制代码



IIS6

  • RewriteRule ^(.*)/([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html(\?(.*))*$ $1/index\.php\?moduleid=$2&catid=$3&itemid=$4&page=$5

[color=rgb(51, 102, 153) !important]复制代码

  • RewriteRule ^([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html(\?(.*))*$ index\.php\?moduleid=$1&catid=$2&itemid=$3&page=$4

[color=rgb(51, 102, 153) !important]复制代码



IIS7+

  • <match url="^(.*)/([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$" />
  • <action type="Rewrite" url="{R:1}/index.php?moduleid={R:2}&amp;catid={R:3}&amp;itemid={R:4}&amp;page={R:5}"/>

[color=rgb(51, 102, 153) !important]复制代码

  • <match url="^([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html\?*(.*)$" />
  • <action type="Rewrite" url="index.php?moduleid={R:1}&amp;catid={R:2}&amp;itemid={R:3}&amp;page={R:4}"/>

[color=rgb(51, 102, 153) !important]复制代码



Zeus

  • match URL into $ with ^(.*)/([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html$
  • if matched then
  • set URL = $1/index.php?moduleid=$2&catid=$3&itemid=$4&page=$5
  • endif

[color=rgb(51, 102, 153) !important]复制代码

  • match URL into $ with ^([0-9]+)-([0-9]+)-([0-9]+)-([0-9]+)\.html$
  • if matched then
  • set URL = index.php?moduleid=$1&catid=$2&itemid=$3&page=$4
  • endif

[color=rgb(51, 102, 153) !important]复制代码


回复

使用道具 举报

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

本版积分规则

QQ|小黑屋|手机版|Archiver|destoon采集论坛

GMT+8, 2025-11-23 04:52 , Processed in 0.014611 second(s), 21 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

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