iis7 redirect (301)

Topics: ASP.NET 2.0
Feb 8, 2010 at 8:06 PM

I am trying to redirect all of my blogengine like urls to my wordpress blog but struggling to accomplish this task.  Please help!

blogengine url format: http://www.mydomain.com/post/2010/02/07/this-is-the-post-title.aspx

wordpress url: http://www.mydomain.com/2010/02/07/this-is-the-post-title/

I've added a new rule along with the wordpress rule for some reason i am getting the old 404 error when I try the blogengine url format.

The site is hosted on ISS7 and PHP5 (godaddy windows shared hosting)

please have a look at my web.config and let me know if i am doing anything wrong:

        <rule name="Redirect(301) all BlogEngine posts">
            <match url="(/20[0-9][0-9]/\d{2}/\d{2}/)(.*).aspx" />
            <action type="Rewrite" url="{R:0}{R:1}/" />
        <rule name="wordpress" patternSyntax="Wildcard">
         <match url="*" />
              <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
              <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
          <action type="Rewrite" url="index.php" />

Please Note: the wordpress rewrite  rule works fine.