.htaccess 301 redirect help

Status
Not open for further replies.

skeets

New Member
Messages
39
Reaction score
0
Points
0
Hi, I recently got myself a domain name, and I'd like to switch my google listings from http://skeets.x10hosting.com/ to http://www.skeetshd.com/

I've read about htaccess 301 redirects but I can't get it to work. I put in:

redirect 301 / http://www.skeetshd.com/

and Firefox spits out:

The page isn't redirecting properly. Firefox has detected that the server is redirecting the request for this address in a way that will never complete.
* This problem can sometimes be caused by disabling or refusing to accept cookies.

IE loads the main page, but I have IFRAMES on it, and it won't load the content of those pages. It also won't load any link I try to click.


Any help to how I can redirect everyone to http://www.skeetshd.com/ ?? Thanks!
 

rockee

New Member
Messages
120
Reaction score
0
Points
0
Try this as I use these rules for a production site hosted on another server which works in all browsers and is Google friendly:
RewriteEngine on
rewritecond %{http_host} ^skeets.x10hosting.com [nc]
rewriterule ^(.*)$ http://www.skeetshd.com/$1 [r=301,nc]
Incidentally, when I tested your X10 sub domain in my browser it resulted in redirecting to your main domain and showing the main domain address in my browser - SeaMonkey - just as you are trying to do.
Tip, empty your browser's cache from time to time when developing.

Regards,
Rocky
 
Last edited:

skeets

New Member
Messages
39
Reaction score
0
Points
0
Never mind, I figured it out...

I just used the code designed to add a www. to the front of the URL...

RewriteEngine On
rewritecond %{http_host} ^skeets.x10hosting.com
rewriteRule ^(.*) http://www.skeetshd.com/$1 [R=301,L]

Edit: Thanks Rocky, you posted while I was typing.

Will Google eventually change its URLs over to skeetshd.com?
 
Last edited:

rockee

New Member
Messages
120
Reaction score
0
Points
0
You have control over the GoogleBot by going to their site and registering, logging in and finding the Webmasters tools - great place for you to make sure all is well for the GoogleBot to spider your site.

Regards,
Rocky
 

skeets

New Member
Messages
39
Reaction score
0
Points
0
I've done that, but I registered as skeets.x10hosting.com, and I don't see any magic renaming button... I was fooling with all this 301 stuff so I wouldn't have to delete what they've already indexed.
 

rockee

New Member
Messages
120
Reaction score
0
Points
0

skeets

New Member
Messages
39
Reaction score
0
Points
0
I added the new domain in the AMP but also parked skeets.x10hosting.com in Cpanel, so that links there would still work. I suppose I could just delete that parked domain.

Thanks for explaining all this. Domains have been by far the most confusing part of this whole process, including teaching myself PHP and MySQL.
 
Status
Not open for further replies.
Top