Using IIS for redirects with wordpress config
-
Hi, I have a new single WordPress install. I am trying to include redirects of old pages from before I used wordress that are .asp pages, with IIS Web.RewriteMaps.config. However I try and include in my web.config file the <rewriteMaps configSource=”Web.RewriteMaps.config”></rewriteMaps> its redirects simply go to 404 wobblys.
In my web.config I dont have a <httpErrors errorMode=”Custom” existingResponse=”Auto”>
for 404s so I wonder if there is something in wordpress that is sending everything 404 and stopping the redirects from working<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <rewrite> <rewriteMaps configSource="Web.RewriteMaps.config"></rewriteMaps> <rules> <clear /> <rule name="WordPress Rule 1" stopProcessing="true"> <match url="^index\.php$" ignoreCase="false" /> <action type="None" /> </rule> <rule name="WordPress Rule 2" stopProcessing="true"> <match url="^wp-admin$" ignoreCase="false" /> <action type="Redirect" url="wp-admin/" redirectType="Permanent" /> </rule> <rule name="WordPress Rule 3" stopProcessing="true"> <match url="^" ignoreCase="false" /> <conditions logicalGrouping="MatchAny"> <add input="{REQUEST_FILENAME}" matchType="IsFile" ignoreCase="false" /> <add input="{REQUEST_FILENAME}" matchType="IsDirectory" ignoreCase="false" /> </conditions> <action type="None" /> </rule> <rule name="WordPress Rule 4" stopProcessing="true"> <match url="^(wp-(content|admin|includes).*)" ignoreCase="false" /> <action type="Rewrite" url="{R:1}" /> </rule> <rule name="WordPress Rule 5" stopProcessing="true"> <match url="^([_0-9a-zA-Z-]+/)?(.*\.php)$" ignoreCase="false" /> <action type="Rewrite" url="{R:2}" /> </rule> <rule name="WordPress Rule 6" stopProcessing="true"> <match url="." ignoreCase="false" /> <action type="Rewrite" url="index.php" /> </rule> </rules> </rewrite> <defaultDocument> <files> <clear /> <add value="index.php" /> </files> </defaultDocument> </system.webServer> </configuration>
Any pointers would be a great help.
Thanks
Richard
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Using IIS for redirects with wordpress config’ is closed to new replies.