T
T
Timur Malyshev2015-12-29 19:17:50
htaccess
Timur Malyshev, 2015-12-29 19:17:50

How to configure htaccess to redirect domains with an A-record to subdomains of another site?

Dear experts! There are site1.ru and site2.ru domains, they have an A-record on othersite.ru. There are subdomains sub1.othersite.ru and sub2.othersite.ru.
Question: how to register htaccess so that domains lead to the corresponding subdomains, but not with a redirect, but with saving the URL, for example site1.ru/catalog/15 led to sub1.othersite.ru/catalog/15 and at the same time site1 remained in the browser line. en/catalog/15?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vlad Zhivotnev, 2015-12-29
@TimurMalyshev

To do this, you do not need to climb into htaccess, but prescribe ServerAlias ​​in the Apache config.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question