Answer the question
In order to leave comments, you need to log in
How to create virtual host configs so that they don't redirect to another site?
In general, there are such configs:
<VirtualHost 5.3.111.2:80>
ServerName mysite.ru
ServerAlias www.mysite.ru
ServerAlias *.mysite.ru
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.mysite.ru$
RewriteCond %{HTTP_HOST} ^((.*)\.)mysite.ru$
RewriteRule ^/(.*) /%2/$1
DocumentRoot /home/mysite/public_html
AssignUserID mysite mysite
CustomLog /home/mysite/logs/mysite.ru.access.log combined
ErrorLog /home/mysite/logs/mysite.ru.error.log
DirectoryIndex index.php
<Directory /home/mysite/public_html>
Options +Includes -ExecCGI
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
Answer the question
In order to leave comments, you need to log in
Check what is written in the config of the site, which, as you say, is opened by mysite.ru. Is this domain also listed there
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question