Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/wordpress/11.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Wordpress-IIS 7.5-URL重写-禁止OWA和RWW 403.18_Wordpress_Iis_Url Rewriting - Fatal编程技术网

Wordpress-IIS 7.5-URL重写-禁止OWA和RWW 403.18

Wordpress-IIS 7.5-URL重写-禁止OWA和RWW 403.18,wordpress,iis,url-rewriting,Wordpress,Iis,Url Rewriting,此规则位于我的wwwroot文件夹中,它修复了我的URL,但破坏了我的OWA和RWW网站 如何向该规则添加异常或条件,使其忽略特定地址?正常情况下,我正在尝试处理域名remote.mydomain.com 使用上述规则,remote.mydomain.com将返回403错误。您只需在规则中添加一个条件即可: <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer>

此规则位于我的wwwroot文件夹中,它修复了我的URL,但破坏了我的OWA和RWW网站

如何向该规则添加异常或条件,使其忽略特定地址?正常情况下,我正在尝试处理域名remote.mydomain.com


使用上述规则,remote.mydomain.com将返回403错误。

您只需在规则中添加一个条件即可:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="Main Rule" stopProcessing="true">
                    <match url=".*" />
                    <conditions logicalGrouping="MatchAll">
                        <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>
    </system.webServer>
</configuration>

状况

<rule name="Main 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="{HTTP_HOST}" pattern="^remote\.mydomain\.com$" negate="true" />
    </conditions>
    <action type="Rewrite" url="index.php" />
</rule>
`

如果请求的主机正好是
remote.mydomain.com

非常感谢,您解决了我的问题,将阻止触发您的规则!我真的很感谢你花时间回答并帮助解释这种情况的原因和方式。继续努力,再次感谢你!
<add input="{HTTP_HOST}" pattern="^remote\.mydomain\.com$" negate="true" />`