I'm having a problem with URL Rewrite, it seems that my rules work if they are rewritten to an aspx page, but if I try to rewrite them to a php page they 404 on me. Yes I have PHP running, IIS7 etc.
<rule name="wordpress1" enabled="true">
<match url="^([_0-9a-z-]+)\.html" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="article.aspx?name={R:1}" logRewrittenUrl="true" />
</rule>
the above works perfectly, however the below fails with a 404.
<rule name="wordpress2" enabled="true">
<match url="^([_0-9a-z-]+)\.html" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?name={R:1}" logRewrittenUrl="true" />
</rule>
You can browse to index.php?name=whatever and it works as well, the rewrite just won't make it happen.
Any ideas?
<rule name="wordpress1" enabled="true">
<match url="^([_0-9a-z-]+)\.html" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="article.aspx?name={R:1}" logRewrittenUrl="true" />
</rule>
the above works perfectly, however the below fails with a 404.
<rule name="wordpress2" enabled="true">
<match url="^([_0-9a-z-]+)\.html" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?name={R:1}" logRewrittenUrl="true" />
</rule>
You can browse to index.php?name=whatever and it works as well, the rewrite just won't make it happen.
Any ideas?