【发布时间】:2014-12-09 08:28:03
【问题描述】:
我需要为单个页面执行 URL 重定向。如果客户访问https://example.com/default.aspx 我需要发送到http://example.com/default.aspx 并且到目前为止收效甚微。谁能阐明限制指向哪个页面的最佳方法?
目前我所拥有的正在工作,但会导致我想要成为 https 的页面出现重定向循环。
<rule name="ForceNonHttps" stopProcessing="true">
<match url="(.*)default/(.*)" ignoreCase="true" negate="true" />
<conditions>
<add input="{SERVER_PORT}" pattern="^443$" />
</conditions>
<action type="Redirect" redirectType="Found" url="http://{HTTP_HOST}{REQUEST_URI}" />
</rule>
【问题讨论】: