It will remain fr.somewhere.com
by default but it will arrive at the server that handles somewhere.com
requests. Inside there, in server's .htaccess
, the %{HTTP_HOST}
variable will contain fr.somewhere.com
for such requests. You can base your resource mapping on that.
If you would want to rewrite it to somewhere.com
, you can simply do it like this in .htaccess.
as well.
RewriteCond %{HTTP_HOST} =fr.somewhere.com
RewriteRule ^(.*)$ http://www.somewhere.com/$1 [R=permanent,L]
Note, that %{HTTP_HOST}
will actually be fr.somewhere.com
and if that condition matches, it will redirect (HTTP 301) to www.somewhere.com
an append the path $1
.
I have a CNAME record created for blog.legoservices.com
which just points to tumblr, but all you see is blog.legoservices.com
.