Irish SEO,  Marketing & Webmaster Discussion

 

301 redirect question

This is a discussion on 301 redirect question within the Coding Help forums, part of the Webmaster Help category; I’m moving my site from irishwidget.com to widget.ie I’m using this Code: <? Header( "HTTP/1.1 301 Moved Permanently" ); Header( ...


Go Back   Irish SEO, Marketing & Webmaster Discussion > Webmaster Help > Coding Help

Register Forum Rules FAQDonate Members List Calendar Search Today's Posts Mark Forums Read


Notices

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 24-01-2007, 11:50 PM
Frontpage User
 
Join Date: Dec 2006
Posts: 21
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
JamesA will become famous soon enough
Default 301 redirect question

I’m moving my site from irishwidget.com to widget.ie

I’m using this

Code:
<? 
Header( "HTTP/1.1 301 Moved Permanently" ); 
Header( "Location: http://www.widget.ie/test.htm" ); 
?>
If I put the code into my header and it appears on (irishwidget.com/test.htm) should it be able to locate the same page (widget.ie/test.htm) on the new domain.
It just seems to redirect to widget.ie

Will it hurt if all the pages on irishwidget.com redirect to the homepage of widget.ie? Is this the best way to move to a new domain and retain my google trafic?

Any help appreciated.
__________________
HarmonicaClub.com | atheist.ie | catholic.ie

Last edited by JamesA; 24-01-2007 at 11:53 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #2 (permalink)  
Old 25-01-2007, 01:04 AM
blacknight's Avatar
Web Slave
Recent Blog:
 
Join Date: Jan 2006
Location: Ireland
Posts: 6,287
blacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to behold
Send a message via ICQ to blacknight Send a message via AIM to blacknight Send a message via MSN to blacknight
Default

If you're on Apache:
http://www.irishwebmasterforum.com/s...d_rewrite.html
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3 (permalink)  
Old 25-01-2007, 08:08 AM
RedCardinal's Avatar
Richard Hearne
 
Join Date: Feb 2006
Posts: 941
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
RedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to behold
Default

Quote:
Originally Posted by JamesA View Post
I’m moving my site from irishwidget.com to widget.ie

I’m using this

Code:
<? 
Header( "HTTP/1.1 301 Moved Permanently" ); 
Header( "Location: http://www.widget.ie/test.htm" ); 
?>
If I put the code into my header and it appears on (irishwidget.com/test.htm) should it be able to locate the same page (widget.ie/test.htm) on the new domain.
It just seems to redirect to widget.ie

Will it hurt if all the pages on irishwidget.com redirect to the homepage of widget.ie? Is this the best way to move to a new domain and retain my google trafic?

Any help appreciated.
Best way is probably to redirect oldPageA -> newPageA, oldPageB -> newPageB using .htaccess in link above from Michele.

If your site is very large (hundreds or thousands of pages) then it is bext to do this in chunks so as not to confuse the spiders.
__________________
Search Engine Optimisation - Red Cardinal Internet Marketing
Internet Consultant Ireland | Search Engine Optimisation Services
Catering Company Dublin - My sister's handmade canape company!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4 (permalink)  
Old 25-01-2007, 08:12 AM
blacknight's Avatar
Web Slave
Recent Blog:
 
Join Date: Jan 2006
Location: Ireland
Posts: 6,287
blacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to behold
Send a message via ICQ to blacknight Send a message via AIM to blacknight Send a message via MSN to blacknight
Default

With my method you can do one page or a million pages at once
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5 (permalink)  
Old 25-01-2007, 08:20 AM
RedCardinal's Avatar
Richard Hearne
 
Join Date: Feb 2006
Posts: 941
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
RedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to behold
Default

Quote:
Originally Posted by blacknight View Post
With my method you can do one page or a million pages at once
Sorry, didn't read it. Just assumed it was for .htaccess.

Will read now though...

Oh, BTW, you dont ever want to redirect millions of pages at once. Google have stated that the spider will choke and it's likely to harm your rankings.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6 (permalink)  
Old 25-01-2007, 08:25 AM
blacknight's Avatar
Web Slave
Recent Blog:
 
Join Date: Jan 2006
Location: Ireland
Posts: 6,287
blacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to beholdblacknight is a splendid one to behold
Send a message via ICQ to blacknight Send a message via AIM to blacknight Send a message via MSN to blacknight
Default

You could put it in a .htaccess, but it seems to be more graceful to have two vhosts anyway

Vhost1 - your original domain with mod_rewrite settings in either .htaccess or directly within apache

Vhost2 - your target site ie. where you want it all to end up

As for choking spiders.. I can't see why that would happen unless you were doing really complex redirects ie. mapping multiple paths to multiple destinations
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7 (permalink)  
Old 25-01-2007, 09:01 AM
RedCardinal's Avatar
Richard Hearne
 
Join Date: Feb 2006
Posts: 941
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
RedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to beholdRedCardinal is a splendid one to behold
Default

Quote:
Originally Posted by blacknight View Post
As for choking spiders.. I can't see why that would happen unless you were doing really complex redirects ie. mapping multiple paths to multiple destinations
'choke' might have been the wrong phrase. The spider has no problems with the content, but how the index is created and redirects are processed may be affected by redirecting large quantities of pages in one go.

In essence the spider will eat it up but the index will spit it out.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #8 (permalink)  
Old 27-01-2007, 06:53 PM
Frontpage User
 
Join Date: Dec 2006
Posts: 21
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
JamesA will become famous soon enough
Default

Thanks for all the help guys, I'll probably be back for more when I get around to putting this redirect into practice. At least I know where to start now.

ps: I asked the same question over at webmasterworld without much success. Thanks for putting this place together and being so helpful.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #9 (permalink)  
Old 04-02-2007, 09:18 PM
Frontpage User
 
Join Date: Dec 2006
Posts: 21
Nominated 0 Times in 0 Posts
TOTW/F/M Award(s): 0
JamesA will become famous soon enough
Default

Thanks guys I've gotten this to work
Code:
 
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} irishwidget.com$
RewriteRule ^(.+) http://www.widget.ie/$1 [L,R=301]
But during the transfer I've had to move a folder called "ia" into the cgi-bin, so that, pages that were at irishwidget.com/ia/ are now at widget.ie/cgi-bin/ia/
Is there any thing I can add to get these pages to redirect properly?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #10 (permalink)  
Old 04-02-2007, 09:20 PM
louie's Avatar
Senior Member
 
Join Date: Jan 2006
Location: Dublin, Ireland
Posts: 2,012
Nominated 5 Times in 3 Posts
TOTW/F/M Award(s): 0
louie has much to be proud oflouie has much to be proud oflouie has much to be proud oflouie has much to be proud oflouie has much to be proud oflouie has much to be proud oflouie has much to be proud oflouie has much to be proud of
Send a message via Yahoo to louie Send a message via Skype™ to louie
Default

best option is like this:
Code:
RewriteCond %{HTTP_HOST} ^(www\.)?irishwidget\.com #just in case www is missing from url
RewriteRule ^(.+)  http://www.widget.ie/$1 [L,R=301]
__________________
:. Web Design & Development Web Design Ireland
:. Search Engines Optimization Search Engines Optimization
:. Directory Submission Directory Submission
:. News & Press Release Ireland GiveItSocks.com
:. Used Cars Ireland, Car Parts & Car Audio Cars For Sale, Car Parts & Accessories
:. I Have 2 Find It Directory SEF Directory
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
301, question, redirect

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads

Thread Thread Starter Forum Replies Last Post
Question about 'Adult Oriented' domains SlitheryImp Domains and domaining 68 26-08-2008 02:27 AM
301 redirects - how long? TheMenace Search Engine Optimisation 4 06-09-2007 09:21 PM
IE7 Question blacknight Webmaster Discussion 4 04-10-2006 11:01 PM
301 Redirects on Windows 2003 Gavin Server / Technical Administration Tips and Queries 7 02-10-2006 07:00 PM
Shorter URLs with 301 redirect blacknight Webmaster Discussion 1 31-08-2006 09:08 PM


All times are GMT +1. The time now is 10:20 PM.


Powered by: vBulletin Version 3.7.3, Copyright ©2000 - 2008, Jelsoft Enterprises Limited.
Hosted in Ireland by Blacknight - Test your ISP |Irish Hosting Directory| Armchair.ie|Logo by Eden Web Design|Avatars by Afterglow |Latest Blog Entries | VPS HostingAd Management by RedTyger

Search Engine Friendly URLs by vBSEO 3.2.0