Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

This question already has an answer here:

I am not experienced technical person, and still learning but will try to explain what I have done so far and what my query is.

I have a (hypothetical) domain az-studios.com

On that domain I have 3 subdomains:

london.az-studios.com

newyork.az-studios.com

paris.az-studios.com

Each of them have 301 header redirections as follows:

london.az-studios.com -> www.az-studios.com/london

newyork.az-studios.com -> www.az-studios.com/newyork

paris.az-studios.com -> www.az-studios.com/paris

So I can maintain only one unique HTML document (that appears to be three different paths) I have setup .htaccess to use MOD_REWRITE as follows:

www.az-studios.com/london -> www.az-studios.com?city=london

www.az-studios.com/newyork -> www.az-studios.com?city=newyork

www.az-studios.com/paris -> www.az-studios.com?city=paris

This is so far the existing structure.

I have recently purchased three (hypothetical) keyword rich domains:

movie-studio-london.com

movie-studio-newyork.com

movie-studio-paris.com

What I would like to achieve is to have these three domains pointing as following:

www.movie-studio-london.com -> www.az-studios.com?city=london

www.movie-studio-newyork.com -> www.az-studios.com?city=newyork

www.movie-studio-paris.com -> www.az-studios.com?city=paris

The only tricky thing I can't figure out is how I do that so that from a Google SEO point of view, it does not use 301 redirects, no frame. What I mean is that I want the response sent to the browser not to be a 301 redirect and no jump of url in the adress bar of the browser.

I would like www.movie-studio-london.com to show to visitors (and especially Google bots) as a standard website (with no funny JavaScript, links, 301 redirect, frames etc).

Some of you might scream "duplicate content" but the websites, although using the same index.php are very different.

I am also aware that this could be seen as doorway but these new purchased domains really define (with keywords) my products and what the different websites are about.

Any idea? Any more details, please ask...

Thanks

Vincent

share|improve this question
1  
You already asked this question nearly verbatim: webmasters.stackexchange.com/questions/44155/… If you aren't happy with the answers your received, edit that question to improve it. –  Stephen Ostermiller Feb 27 '13 at 18:13
add comment

marked as duplicate by John Conde Feb 28 '13 at 0:29

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1 Answer

That is not a redirect but a rewrite.

If you are Apache this is done with the .htaccess file. There are many online resources to explain how they work and many relevant questions here.

The principal for having 3 domains share the files is to first create 3 virtual servers which all point to the same document-root. Then you setup the .htaccess file to do the rewriting. It will look something like this:

RewriteEngine On

RewriteCond %{HTTP_HOST} ^movie-studio-london.com$
RewriteRule ^/?(.*)$ /$1/?city=london [QSA]

RewriteCond %{HTTP_HOST} ^movie-studio-paris.com$
RewriteRule ^/?(.*)$ /$1/?city=paris [QSA]

If you have sub-pages you may need to tweak the rules depending on how they are structured.

share|improve this answer
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.