Answer the question
In order to leave comments, you need to log in
How not to fall under the affiliation of sites in Yandex city.site.ru and site.ru?
How not to fall under the affiliation of sites in Yandex city.site.ru and site.ru?
In order not to create copies of sites for each branch, I made DNS records like
city.site.ru. CNAME site.ru.
made in the site template
switch ($_SERVER["SERVER_NAME"]) {
case 'msk.site.ru':
...
case 'spb.site.ru':
...
Answer the question
In order to leave comments, you need to log in
Shouldn't hit. You did everything right. Also indicate the city in all title pages and on the pages of product cards, delivery conditions and other things that apply to the city. Everything else will be 100% ok.
Also, add all subdomains to the webmaster and assign the desired region to each.
I do city.site.ru in DNS
. CNAME site.ru.
site.ru is displayed, in the address bar city.site.ru - everything is as it should, but the certificate from site.ru is pulled up and does not fit city.site.ru.
If I make a redirect through htaccess, then the site.ru domain will already be in the address bar
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question