ppypp伦理天堂,91手机在线视频,免费在线观看黄色毛片,夜夜穞天天穞狠狠穞AV美女按摩

聯系官方銷售客服

1835022288

028-61286886

投訴 分享 win服務器下 子目錄 子站 偽靜態方法分享 2 0
Swlts(全能人才) SVIP會員 OEM版權 2022-08-04 15:08:30 私信
迅睿CMS版本:4.5.6 #iis #iis偽靜態

win服務器下 子目錄 子站偽靜態辦法分享。 原理很簡單,分享給大家。就是用location 標簽 區分 主站和子目錄的重寫規則 web.config

雖然目前Linux用戶很多,win服務器也有很多用戶使用。

根目錄下的 web.config

<?xml version="1.0" encoding="UTF-8"?>
<configuration>


<location path="." allowOverride="false" inheritInChildApplications="false">

    <system.webServer>
        <rewrite>
            <rules>
                <rule name="已導入的規則 1" stopProcessing="true">
                    <match url=".(js|ico|gif|jpe?g|bmp|png|css)$" negate="true" />
                    <conditions logicalGrouping="MatchAll">
                        <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
                        <add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" />
                    </conditions>
                    <action type="Rewrite" url="/index.php" />
                </rule>
            </rules>
        </rewrite>
    </system.webServer>
 
 
</location>
 
</configuration>

子目錄下的 web.config

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="已導入的規則2" stopProcessing="true">
                    <match url=".(js|ico|gif|jpe?g|bmp|png|css)$" negate="true" />
                    <conditions logicalGrouping="MatchAll">
                        <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
                        <add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" negate="true" />
                    </conditions>
                    <action type="Rewrite" url="/en/index.php" />
                </rule>
            </rules>
        </rewrite>
    </system.webServer>
</configuration>

其中/en/ 改成你當前子目錄名稱。

以上,用得著的朋友,幫回帖支持下。

解決方案