Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/url/2.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
.htaccess URL重写IIS_.htaccess_Url_Iis_Url Rewriting - Fatal编程技术网

.htaccess URL重写IIS

.htaccess URL重写IIS,.htaccess,url,iis,url-rewriting,.htaccess,Url,Iis,Url Rewriting,在IIS上重写URL时出现问题 我正试图将URL从“/…/…/…/members”重写为“/members”,但它没有 当我将该规则用作.htaccess规则时,我已经从导入了该规则,我刚刚收到错误“404-未找到” 代码如下所示: IIS web.config: <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer>

在IIS上重写URL时出现问题

我正试图将URL从“/…/…/…/members”重写为“/members”,但它没有

当我将该规则用作.htaccess规则时,我已经从导入了该规则,我刚刚收到错误“404-未找到”

代码如下所示: IIS web.config:

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="Imported Rule 1" stopProcessing="true">
                    <match url="^(.*)$" />
                    <conditions logicalGrouping="MatchAll">
                        <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" negate="true" />
                        <add input="{REQUEST_FILENAME}.php" matchType="IsFile" ignoreCase="false" />
                    </conditions>
                    <action type="Rewrite" url="{R:1}.php" />
                </rule>
                <rule name="Imported Rule 1-1" stopProcessing="true">
                    <match url="^members/(.*)$" />
                    <action type="Rewrite" url="/fbsCMS/fbs_CDN/fbs_CONTENT/fbs_MEMBERS/{R:1}" />
                </rule>
            </rules>
        </rewrite>
    </system.webServer>
</configuration>

请有人解释一下为什么它不允许它。

为什么这个问题被标记为“.htaccess”?它与ApacheHTTP服务器无关。