迅睿開源框架是一款PHP8高性能·簡單易用的PHP開源開發(fā)框架, 基于MIT開源許可協(xié)議發(fā)布,不限制商業(yè)使用,以多端互聯為設計理念, 支持的微信公眾號、小程序、APP客戶端、移動端網站、PC網站等多終端式管理系統(tǒng)。
業(yè)務經理
微信掃描以上二維碼
028-61286886
技術咨詢
多網站系統(tǒng)設置目錄模式 sitemap.xml 無法訪問
回復@帝國織夢開發(fā) 請問如何設置,在哪里設置
本地使用iis服務器,需要在網站根目錄創(chuàng)建web.config,配置如下,根據實際情況修改調整:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<!-- 主站點規(guī)則 -->
<rule name="Main Site Rule" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{REQUEST_URI}" pattern="\.(js|ico|gif|jpe?g|bmp|png|css)$" negate="true" />
<add input="{REQUEST_URI}" pattern="^/en/" negate="true" />
</conditions>
<action type="Rewrite" url="/index.php" />
</rule>
<!-- /en目錄規(guī)則 -->
<rule name="EN Directory Rule" stopProcessing="true">
<match url="^en/(.*)" />
<action type="Rewrite" url="/en/index.php?path={R:1}" />
</rules>
</rewrite>
</system.webServer>
</configuration>
回復@帝國織夢開發(fā) 請問如何設置,在哪里設置
本地使用iis服務器,需要在網站根目錄創(chuàng)建web.config,配置如下,根據實際情況修改調整:
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<!-- 主站點規(guī)則 -->
<rule name="Main Site Rule" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{REQUEST_URI}" pattern="\.(js|ico|gif|jpe?g|bmp|png|css)$" negate="true" />
<add input="{REQUEST_URI}" pattern="^/en/" negate="true" />
</conditions>
<action type="Rewrite" url="/index.php" />
</rule>
<!-- /en目錄規(guī)則 -->
<rule name="EN Directory Rule" stopProcessing="true">
<match url="^en/(.*)" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{REQUEST_URI}" pattern="\.(js|ico|gif|jpe?g|bmp|png|css)$" negate="true" />
</conditions>
<action type="Rewrite" url="/en/index.php?path={R:1}" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>