Msg#: 4550634 posted 12:45 pm on Mar 3, 2013 (gmt 0)
I did a search on the term redirect and tried some of the things explained in the posts I found, but I just can't get this to work.
I have an aged WordPress blog with over 500 pages indexed in Google that I no longer want to make available to the public. The domain is example.com where example is my first and last name. This blog is hosted on a shared Linux server from Hostgator.
I have another relatively new WordPress blog that is hosted on a dedicated Linux server, also with Hostgator. What I'm trying to do is redirect all search engine traffic from all pages indexed in Google for the old domain to the home page of the other blog.
In other words I need to do a redirect from all pages of domain #1 to the index page of domain #2 which is on a different server.
I've tried everything from simple "Redirect 301" statements to complicated rewrite rules in .htaccess and the old pages ALWAYS try to redirect to a corresponding page on the new site (which of course do not exist and never will, resulting in a 404 error). Right now the 404 page on the new blog is catching all the traffic to the non-existent pages but I would really prefer having it redirected straight to the home page if possible (and I realize that it might not be).
Help with the coding of a redirect that works the way I need it to work will be GREATLY appreciated. Thanks in advance, and sorry for the rambling explanation!
Msg#: 4550634 posted 11:30 pm on Mar 3, 2013 (gmt 0)
If I'm reading your first post correctly, the two domains live in different places-- different physical servers, even --so requests for Old Blog and requests for New Blog will never set eyes on each other. This simplifies things a lot.
The one thing you don't say is where your attempted redirects are located. If they are anywhere other than the old site's htaccess, requests will never see them so they can have no effect.
A Redirect by that name will not work. You can use RedirectMatch if and only if the old site does not use mod_rewrite at all. If it does, you will have to make your redirect using mod_rewrite. But that's trivial.
The most important thing is getting the redirect rule in the right location.
:: pause here to admire the way everyone is sitting on their hands w/r/t the "redirect everything to home page" aspect ;) ::