供应模块绑定二级域名后,设置伪静态出现404
供应模块绑定二级域名后,设置伪静态出现4041、二级域名绑定了sell目录
2、后台模块设置了域名
3、服务器绑定了域名
4、Nginx使用的官方规则。
问题:不绑定二级域名伪静态访问正常。绑定二级域名动态正常,静态404
跪求大佬看看是什么情况
可以到官方文档哪里搜索看看
绑定的二级域名这个也添加了规则吗?
zhao90 发表于 2017-8-2 17:39
绑定的二级域名这个也添加了规则吗?
二级域名规则 跟 WWW域名用的同一个伪静态文件。
Nginx的伪静态配置发一下
你最好复制一个sell目录重命名 然后绑定二级域名 在站点里面设置伪静态
给sell目录配置的二级域名,配置文贴出来看下
龙在天涯 发表于 2017-8-3 08:28
给sell目录配置的二级域名,配置文贴出来看下
#二级域名域名绑定子目录
if ( $host = 'sell.128pu.com' ){
set $subdomain "/sell";
}
#任何主域不是test.com的解析都转向444。彻底断绝网站被非法镜像、非法解析、非法反代!
if ( $host !~* (.*?).128pu.com ) { return 444;}
#Destoon 伪静态规则
rewrite ^/(.*)\.(asp|aspx|asa|asax|dll|jsp|cgi|fcgi|pl)(.*)$ /404.php last;
rewrite ^/(.*)/(admin|cache|editor|file|include|lang|module|skin|message|template)/(.*)\.php(.*)$ /404.php last;
rewrite ^/(.*)-htm-(.*)$ /$1.php?$2 last;
rewrite ^/(.*)/show-(+)([\-])?(+)?\.html$ /$1/show.php?itemid=$2&page=$4 last;
rewrite ^/(.*)/list-(+)([\-])?(+)?\.html$ /$1/list.php?catid=$2&page=$4 last;
rewrite ^/(.*)/show/(+)/(+)?([/])?$ /$1/show.php?itemid=$2&page=$3 last;
rewrite ^/(.*)/list/(+)/(+)?([/])?$ /$1/list.php?catid=$2&page=$3 last;
rewrite ^/(.*)/(+)-c(+)-(+)\.html$ /$1/list.php?catid=$3&page=$4 last;
rewrite ^/(.*)/(+)-(+)-(+)-(+)\.html$ /$1/index.php?moduleid=$2&catid=$3&itemid=$4&page=$5 last;
rewrite ^(.*)/(+)/(.*)\.shtml$ $1/$2/index.php?rewrite=$3 last;
rewrite ^/(com)/(+)/(+)/(.*)\.html$ /index.php?homepage=$2&file=$3&rewrite=$4 last;
rewrite ^/(com)/(+)/(+)([/])?$ /index.php?homepage=$2&file=$3 last;
rewrite ^/(com)/(+)([/])?$ /index.php?homepage=$2 last;
zhao90 发表于 2017-8-2 18:07
Nginx的伪静态配置发一下
贴出来了,麻烦了。大佬们
static/image/smiley/grapeman/01.gif
页:
[1]