I added UrlRewriter.net to my site today and it works fine with redirecting my SEO links to actual pages. The question is if there is any way to keep my old links in site and have ResolveUrl() using the rules to output links in my page. The "old" links should never be viewed by either search bots or users.
Example link in page:
<a href="<%= ResolveUrl("~/Help.aspx") %>">Help</a>
I added rewrite code like this in web.config:
<rewrite url="~/help" to="~/help.aspx" />
<rewrite url="~/help/(.+)" to="~/help.aspx?section=$1" />
First it would be great to have the links rendered without any extra job like MVC has. The second best is if there is a nice way to just add rules for "the other way" as well in the rewrite list.
This would also enable me to easally turn off/on redirecting when debugging.