Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years.

Thanks,

CNET Support

Question

301 redirect

Oct 27, 2011 1:39PM PDT

I'm using GoDaddy with several websites as alias's to my main site.

I want to do a 301 redirect from ccwtech.com to www.ccwtech.com without causing other alias (subdirectory sites) to have issues.

I tried this code, but it causes the alias sites to be shown wrong.

Options +FollowSymlinks
RewriteEngine ON
RewriteCond %{HTTP_HOST} ^ccwtech.com [NC]
RewriteRule ^(.*)$ http://www.ccwtech.com/$1 [R=301,NC]

(if GoDaddy Alias's isn't familiar to you, it allows you to have a seperate url (like www.lonepeakvet.com and it really is www.ccwtech.com/lonepeak [for example].

When I use that redirect to get non-www to www on my main site, it then shows www.lonepeakvet.com as www.ccwtech.com/lonepeakvet [example only].

Any help?

Discussion is locked