On my iis7 box, I have a url rewrite rule in my web.config that keeps all of my urls lowercase:
<rule name="LowerCaseRule1" stopProcessing="false">
<match url="^((?=.*[A-Z]).*\.aspx)(.*)" ignoreCase="false" />
<action type="Redirect" url="{ToLower:{R:1}}{R:2}" />
</rule>
This has been working well, but it also rewrites my AJAX WebMethod calls when they contain any capitals letters. Consequently the methods don't get called. An obvious solution is to keep all WebMethods lowercase, but it would be way more appropriate to attack it on the front from the rewrite's regex.
Currently:
/Default.aspx ==> /default.aspx
/Default.aspx/UpdateOrder ==> /default.aspx/updateorder
I'd like the latter example to rewrite to /default.aspx/UpdateOrder
My regex skills just can't get me there.
Thanks in advance, John