IIS Url Rewrite Capturing query string and escaping characters

Posted by LiamB on Server Fault See other posts from Server Fault or by LiamB
Published on 2013-10-22T09:34:45Z Indexed on 2013/10/22 9:57 UTC
Read the original article Hit count: 326

Filed under:
|

We are just adding some redirects for an old site to a new one in IIS7 using the URL Rewrite 'plugin'.

The old site's URL are all based on the query string, we'd usually do explicit rewrites like below. But this wont work in the case of the query string.

<rule name="Redirect-1" patternSyntax="Wildcard" stopProcessing="true">
    <match url="index.php?option=m_content&view=article&id=15&Itemid=16" />
    <action type="Redirect" url="http://newurl/some-page" />
</rule>

So using the 2 URL's above how can we do a 301 redirect?

© Server Fault or respective owner

Related posts about iis7

Related posts about rewrite