I have a this rewrite rule currently in place on IIS:
<rewrite>
<rules>
<rule name="rewrite asp">
<!--Removes the .asp extension for all pages.-->
<match url="(.*)" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{REQUEST_FILENAME}" negate="true" pattern="(.*).asp" />
</conditions>
<action type="Rewrite" url="{R:1}.asp" />
</rule>
</rules>
</rewrite>
This enables this:
site.com/allpages --> site.com/allpages.asp
Now, is it possible to create an exception so that a particular page rewrites to another extension?
site.com/exception --> site.com/exception.php
Create another rule, which is above the 'asp' rule with match pattern:
and action: