互点宝cms遇到404问题解决办法
分类:使用方法 作者:互点宝 Tag:发布时间:2023-12-28
查看:104 次

出现这个页面是服务器环境问题。可以根据不同服务器环境配置文件。
配置文件
Apache伪静态:.htaccess
<IfModule mod_rewrite.c>
Options +FollowSymlinks -Multiviews
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?s=$1 [QSA,PT,L]
</IfModule>
Nginx伪静态:nginx.conf
location / {
if (!-e $request_filename){
rewrite ^(.*)$ /index.php?s=$1 last; break;
}
}
IIS伪静态:web.config
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="OrgPage" stopProcessing="true">
<match url="^(.*)$" />
<conditions logicalGrouping="MatchAll">
<add input="{HTTP_HOST}" pattern="^(.*)$" />
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="index.php?s={R:1}" />
</rule>
<rule name="BlockDirectDownload" enabled="true" stopProcessing="true">
<match url="(?:asp|aspx|jsp|asa|dll|cgi|fcgi|htm)$" ignoreCase="true" />
<conditions>
<add input="{HTTP_REFERER}" pattern="^http://(.*.)?(abc.net)/.*$" negate="true" />
</conditions>
<action type="CustomResponse" statusCode="404" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
配置好后即可。
上一篇:互点宝cms标签
下一篇:互点宝cms安装