?
Solved

301 redirect / Duplicate Content

Posted on 2010-01-08
2
Medium Priority
?
335 Views
Last Modified: 2012-05-08
Hello Experts,

I have registred 4 different domains:

testdomain.de
testdomain.ch
testdomain.at
testdomain.com

Currently all Domains are redirected to the same Host, so a visitor gets the same content whatever domain he uses.

I would like to change that now - i only want to the use the testdomain.COM as the main domain, and redirect like the following:

testdomain.de --> de.testdomain.com
testdomain.ch --> ch.testdomain.com
testdomain.at --> at.testdomain.com

My questions are the following:

1. How can I realize that regarding that I want my indexed google links to work also in the future. I read sth about a 301 redirect but I´m not sure about that.

2. Will Google regard my content as duplicate content, since i still have the same content on

ch.testdomain.com
and
de.testdomain.com
and
at.testdomain.com
(and also of course testdomain.com itself)
0
Comment
Question by:bibabutze
2 Comments
 
LVL 2

Expert Comment

by:xpert13
ID: 26209817
1. With 301 redirect everything will be fine. It is normal method

2. No, Google will think that those domains are mirrors
0
 
LVL 26

Accepted Solution

by:
arober11 earned 1000 total points
ID: 26274029
Hi

I take there is a DNS 'A' record, for "testdomain.com", while:
- testdomain.de
- testdomain.ch
- testdomain.at
are just CNAME entries (http://en.wikipedia.org/wiki/CNAME_record_ to that domain, you can check via a DNS lookup e.g. http://www.dnswatch.info/ 

If "testdomain.com" is just another CNAME, and your using a shared IP and an Apache name based virtual hosts then ignore most of the following.

What you need to do depends on what you plan to do with the sites:
1) Will the be identical copies / same document root?
2) If not identical copies, then how much are you to differentiate the sites / structure the content?
3) Are you looking to add HTTPS / an SSL certificate to any of the variants?

If HTTPS access is requied,  then to avoid browser warnings you'll want to register / add 'A' records for the new:
de.testdomain.com
ch.testdomain.com
at.testdomain.com

And have the the existing CNAME entries modified to point to the new 'A' records:
testdomain.de -> de.testdomain.com
testdomain.ch -> ch.testdomain.com
testdomain.at -> at.testdomain.com

Along with setting up new virtual hosts / generating new SSL certificates for each country.

If no HTTPS access is required you could get away with 3 more CNAMES to the main host, and a few more name based virtual hosts in apache, again all depends what you want / plan to do.

If the sites are to share content you'll need to scan through your site to ensure all local page links are relative, else they'll end up changing domain's as they browse.

Anyway you'll probably want a rewrite rule, along the following lines, in you httpd.conf, to eliminate the old localised site variants.
 
RewriteEngine On
RewriteCond %{HTTP_HOST}    testdomain\.(de|ch|at) [NC]
RewriteRule   .*            http://%1.testdomain.com%{REQUEST_URI} [L,R=301]

Also gets more involved if you have multiple web-servers and a Load balancer.

LEt us know if this is enough or if you require more assistance.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hi, in this article I'm going to teach you how to run your own site, and how to let people in (without IP). I'll talk about and explain each step... :) By the way, everything in this Tutorial is completely free and legal. This article is for …
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
Integration Management Part 2
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Suggested Courses
Course of the Month14 days, 22 hours left to enroll

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question