Subdomain redirect to folder

Topics: User Forum
Feb 17, 2010 at 4:17 PM

I need to do a subdomain redirect to a folder like this:<!--amespace prefix = o ns = "urn:schemas-microsoft-com:office:office"--> to

 my server administrator installed the ISAPI_rewrite into my server and i think that it works good because with other rules it works.

In my web hosting i have a “rewrite” folder with 2 files (isapirewrite4.ini and isapirewrite4.dll). I tried with a simple rule in isapirewrite4.ini and it works good but with a advanced rule to do a subdomain redirect it not works.

 Please help me.  

Feb 17, 2010 at 8:28 PM
Edited Feb 17, 2010 at 8:29 PM

#1 - I recommend that you move to IIRF v2. It's been final/stable for a long while now.  Since August last year.

#2. - your scenario is in the documentation.  For Rewrite:  For Redirect:


Good luck


Feb 19, 2010 at 9:48 AM


i've IIRF right now with this rules:

#RewriteCond  %{HTTP_HOST}  ^(.*)\.domain\.com$
#RedirectRule ^/(.*)$       http://domain/*1/$1         [R=301]

when i go to i redirect to http://mydomain/www 

when i go to i have an error.

It's necessary to include a DNS zone into my domain configuration?


Feb 19, 2010 at 12:31 PM

You reported that you have an error, but you didn't describe the error.

What does the IIRF log say?  the IIS log?


Feb 19, 2010 at 1:28 PM

I don't have access to IIS logs or IIRF logs. My server is administrated by the data center provider. When i go to the error is:

Bad Request (Invalid Hostname)

Feb 19, 2010 at 1:44 PM

Well that sure sounds like it's a DNS problem, not a problem with IIRF.

Good luck!