php - 如何使用web.config重写IIS UrlRewriteModule中的网页的URL?


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

<configuration>

<system.webServer>

<rewrite>

<rules>

<rule name="openbms" patternSyntax="ECMAScript" stopProcessing="true">

<match url="^(.*)$" ignoreCase="true" negate="false" />

<conditions logicalGrouping="MatchAll">

<add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="true" negate="true" />

<add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="true" negate="true" />

</conditions>

<action type="Rewrite" url="index.php?s={R:1}" />

</rule>

</rules>

</rewrite>

</system.webServer>

</configuration>

__________________________________________________________________________________

若有帮助到您,欢迎捐赠支持,您的支持是对我坚持最好的肯定(*^_^*)

你要保守你心,胜过保守一切。

作者:刘俊涛的博客​