Iis URL重写-如果匹配特定字符串,则删除URL结尾
使用URL重写,我们有很多旧的URLIis URL重写-如果匹配特定字符串,则删除URL结尾,iis,iis-7.5,Iis,Iis 7.5,使用URL重写,我们有很多旧的URL /something/else/index.cfm /this/that/index.cfm 我想做的是从这些示例中删除/index.cfm 有什么想法吗 谢谢 <rule name="Remove Trailing Index.cfm" enabled="true"> <match url="^(.*)/index.cfm" /> <conditions logicalGrouping="MatchAll
/something/else/index.cfm
/this/that/index.cfm
我想做的是从这些示例中删除/index.cfm
有什么想法吗
谢谢
<rule name="Remove Trailing Index.cfm" enabled="true">
<match url="^(.*)/index.cfm" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{R:1}" pattern="category" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Redirect" url="/{R:1}" />
</rule>