【发布时间】:2017-10-13 11:34:23
【问题描述】:
我在根文件夹中的 IIS 服务器上安装了 WP。这适用于漂亮的永久链接。
/development 上还有另一个 wordpress 安装,它使用以下 web.config
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="WordPress1" patternSyntax="Wildcard">
<match url="*"/>
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true"/>
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true"/>
</conditions>
<action type="Rewrite" url="index.php"/>
</rule></rules>
</rewrite>
<staticContent>
<clientCache cacheControlCustom="public" cacheControlMode="UseMaxAge" cacheControlMaxAge="365.00:00:00"/>
<remove fileExtension=".woff"/>
<remove fileExtension=".woff2"/>
<mimeMap fileExtension=".woff" mimeType="application/x-font-woff"/>
<mimeMap fileExtension=".woff2" mimeType="application/font-woff2"/>
</staticContent>
</system.webServer>
</configuration>
但是,漂亮的永久链接在此站点的子文件夹中不起作用
主页在这个子文件夹和选择普通永久链接时有效
有什么想法吗?
【问题讨论】:
标签: wordpress iis web-config