PDA

View Full Version : just moved domain names


Xencored
04-03-2009, 02:21 PM
Hi all

Is there anyway to can redirect all my old urls that is found in google
to my new name ?
as there all giving 404 Errors :mad:

Thanks

vbplusme
04-04-2009, 01:49 AM
You probably need to add a redirect in your .htaccess file.


RewriteRule ^old-url\.php$ http://www.example.com/new-url [R=301,L]

veenuisthebest
04-04-2009, 02:16 AM
The better way is to keep your old domains's nameservers same as new one, and add it as a parked domain in cpanel.

And add this in htaccess:-

RewriteEngine On
RewriteCond %{HTTP_HOST} !^newdomain\.com$
RewriteRule ^(.*)$ http://newdomain.com/$1 [L,R=301]


This will take care of everything. All old URL's would point to exact same location in new domain, it will also take care of www vs non-www issue.

Xencored
04-04-2009, 07:12 AM
The better way is to keep your old domains's nameservers same as new one, and add it as a parked domain in cpanel.

And add this in htaccess:-

RewriteEngine On
RewriteCond %{HTTP_HOST} !^newdomain\.com$
RewriteRule ^(.*)$ http://newdomain.com/$1 [L,R=301]


This will take care of everything. All old URL's would point to exact same location in new domain, it will also take care of www vs non-www issue.

Hey thanks i did this my but still the same


RewriteEngine On
RewriteCond %{HTTP_HOST} ^animeisland.co.uk$
RewriteRule ^(.*)$ http\:\/\/www\.myanimeisland\.com\/forums$1 [L,R=301]

veenuisthebest
04-04-2009, 09:28 AM
Its not the same, you have edited my code. Copy paste mine.

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www\.myanimeisland\.co\.uk
RewriteRule (.*) http://www.myanimeisland.co.uk/$1 [R=301,L]



Your new domain is myanimeisland.com , and your preferance is www.