0
我试图让规则工作,即语言标识符在url路径中。如果未指定语言,我们希望强制URL为en版本。例如:IIS URL重写默认语言路径
www.domain.com/page.aspx应该重定向到www.domain.com/en/page.aspx
这里是我们到目前为止的规则,但它一直在重定向结束了循环。
<rule name="Default Language" stopProcessing="true">
<match url="(.*)" />
<conditions>
<add input="{REQUEST_URI}" pattern="^/(en|es|ph)/" negate="true" ignoreCase="true" />
</conditions>
<action type="Redirect" url="/en/{R:1}" redirectType="Permanent" />
</rule>
任何想法哪里会出错?