Answer the question
In order to leave comments, you need to log in
Why does the local server redirect from the virtual host to the stub?
Hello. The problem is this: I installed xampp, uncommented the permission to virtual hosts in the /opt/lampp/etc/httpd.conf file, made a www folder in the home directory (htdocs has too high rights) and in it, in fact, my site. Next edited etc/hosts:
127.0.0.1 localhost
127.0.0.1 my_site.com
127.0.1.1 my_name
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
NameVirtualHost 127.0.0.1:80
<VirtualHost 127.0.0.1:80>
ServerAdmin [email protected]
DocumentRoot "/opt/lampp/htdocs"
ServerName localhost
</VirtualHost>
<VirtualHost 127.0.0.1:80>
DocumentRoot "/home/king/www/my_site.com"
ServerName my_site.com
ServerAlias www.my_site.com
ErrorLog "/logs/my_site-error_log"
CustomLog "logs/my_site-access_log" common
<Directory />
AllowOverride All
Require all dranted
<Directory />
</VirtualHost>
Answer the question
In order to leave comments, you need to log in
The domain name must consist only of letters, numbers and a hyphen "-". The total number of characters in a domain name must not exceed 63 characters.
as an option
As far as I understand nothing about this because of this: .com
as they write on mintmem.com/page/xampp-for-linux-part2
Avoid matching the suffix with real-life domain zones, check, for example, here .
Problem solved: removed ErrorLog and CustomLog lines. maybe someone will come in handy.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question