Go Back   WarriorForum - Internet Marketing Forums > Warrior Support Forums > Website Design
Register Blogs FAQ Social Groups CalendarHelp Desk

Reply
 
LinkBack Thread Tools
Old 03-12-2010, 06:38 AM   #1
ɹoıɹɹɐʍ ǝʌıʇɔɐɹǝdʎɥ
War Room Member
 
RobinInTexas's Avatar
 
Join Date: Dec 2008
Location: Texas
Posts: 239
Thanks: 54
Thanked 21 Times in 19 Posts
Social Networking View Member's FaceBook Profile  View Member's Twitter Profile 
Contact Info
Send a message via Skype™ to RobinInTexas
Default need htaccess help

Have a newly registered site on shared hosting at hostmonster.

Due to the allegedly helpful feature provided by the cpanel of setting all addon domains resolving also as subdomains of the primary, search engines (on their own) discovered:

mynewdomain.primary.com

before finding mynewdomain.com

anybody have an easy way to redirect mynewdomain.primary.com

to mynewdomain.com?

This is for a client site, and I really don't want the client's stuff mixed in with mine and vice-versa

Robin


...Even if you're on the right track, you'll get run over if you just sit there.
RobinInTexas is offline   Reply With Quote
Old 03-12-2010, 03:17 PM   #2
Warrior Member
 
Join Date: Jul 2009
Posts: 17
Thanks: 1
Thanked 0 Times in 0 Posts
Default Re: need htaccess help

Try the following your htaccess file

Code:
# This allows you to redirect your entire website to any other domain
Redirect 301 / full url
You could also do it with PHP

Code:
<?
    Header( "HTTP/1.1 301 Moved Permanently" ); 
    Header( "Location: full-url" ); 
?>
Also you can go to your webmaster tools at least with google and tell it to remove that subdomain from its spidering.

RankPay - Don't Pay Until You Rank - The best in SEO Services.

RankPay features expert SEO analysis. They will REFUSE your generic keywords and will work with you to pick keywords FREE OF CHARGE.
naffets77 is offline   Reply With Quote
Old 03-13-2010, 05:59 AM   #3
ɹoıɹɹɐʍ ǝʌıʇɔɐɹǝdʎɥ
War Room Member
 
RobinInTexas's Avatar
 
Join Date: Dec 2008
Location: Texas
Posts: 239
Thanks: 54
Thanked 21 Times in 19 Posts
Social Networking View Member's FaceBook Profile  View Member's Twitter Profile 
Contact Info
Send a message via Skype™ to RobinInTexas
Lightbulb Re: need htaccess help

I think I solved it:

RewriteEngine On
RewriteCond ^primary\.mynewdomain\.com/$1 [NC]
RewriteRule ^(.*)$ http://www.mynewdomain.com/$1 [R=301,L]

seems to work.

Robin


...Even if you're on the right track, you'll get run over if you just sit there.
RobinInTexas is offline   Reply With Quote
Reply

  WarriorForum - Internet Marketing Forums > Warrior Support Forums > Website Design

Tags
htaccess

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -6. The time now is 09:48 AM.