Share via


Exclude Directory from Rewrite Rules

Question

Wednesday, October 13, 2010 10:44 PM

OK, so I have created a Word Press website using IIS 7 and using the URL rewrite. I have the wordpress installed to the root of the folder and everything works great but I want to add a folder to the site and have it render outside of WP. I have tried everything I can think of to exclude this folder (folder is called "custom" at root of website). Regardless of the rules I've created it always ends up redirecting to the WP - I cannot find this page error. I have tried to program my way with a rule and I have also go to that folder in IIS Manager, go to that folder and disabled all the rules and it still happens. Any suggestions would be great. Thanks, Richard

All replies (1)

Wednesday, October 13, 2010 11:29 PM âś…Answered

Open IIS Manager and click on the URL Rewrite module under your website level, not a directory.

Select your WP rewrite Rule (if you have one) and create a condition where {REQUEST_URI} does not match the Pattern ^/yourdirectory$

You could also review your installation steps here.

http://learn.iis.net/page.aspx/280/install-wordpress-on-iis/