Quantcast
Channel: All Forums
Viewing all articles
Browse latest Browse all 27852

rewrite .htm to /

$
0
0

I'm trying to rewrite .htm to / to accomodate a change in the site

so we'd have www.domain.com/pagename.htm to www.domain.com/pagename/ or www.domain.com/subdir/pagename.htm to www.domain.com/subdir/pagename/

so far I have a simple rule that changes the first level www.domain.com/pagename.htm to www.domain.com/pagename/ and it's working - where it falls down is the levels of subdir.

<rule name="Remove htm">
<match url="^([_0-9a-z-]+).htm$" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="{R:1}/" />

Is this possible? 


Viewing all articles
Browse latest Browse all 27852

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>