• Welcome to Web Hosting Community Forum for Webmasters - Web hosting Forum.
 

Recommended Providers

Fully Managed WordPress Hosting
lc_banner_leadgen_3
Fully Managed WordPress Hosting

WordPress Theme

Divi WordPress Theme
WPZOOM

Forum Membership

Forum Membership

Redirect to www using ISAPI rewrite rule

Started by Rakesh, August 23, 2008, 12:54:18 AM

Rakesh

Hi,

I am not sure if this is the right forum to ask this question. I have site hosted on Windows server running on IIS 6 and I want set redirection to www so that if someone browse domain.com it redirects to www.domain.com.

My Host had told me that they have lite version of ISAPI rewrite installed and I want to provide the rule that should not affect to other domains hosted on the same server. Can someone provide me the guideline to setup this rule?

Thanks in advance.

Rakesh

Kailash

You will need to provide the below code to your hosting provider to set the rule. This rule needs to be write in httpd.ini file:

RewriteCond Host: ^domain\.com
RewriteRule (.*) http\://www\.domain\.com$1 [I,RP]
Replace domain with your actual domain name without TLD and .com with your TLD.

Kailash