Home > Backend Development > PHP Tutorial > xampp configure virtual host

xampp configure virtual host

WBOY
Release: 2016-07-29 09:05:52
Original
1056 people have browsed it

xampp Configure virtual host

xampp The first step to configure virtual host: add virtual host configuration in apache/conf/extra/httpd-vhosts.conf: such as

ServerAdmin a@a. com

DocumentRoot "E:/phpProj/test"

ServerName test.com

ServerAlias ​​www.test.com

ErrorLog "logs/test-error.log"

CustomLog "logs/test-access.log" combined

You can add multiple

ServerAdmin a@a.com

DocumentRoot "E:/phpProj/aa"

ServerName aa.com

ServerAlias ​​www.aa.com

ErrorLog "logs/aa-error.log"

CustomLog "logs/aa-access.log" combined

Step 2: In apache/conf/httpd In .conf, omit

....

to

Options FollowSymLinks

AllowOverride None

Order deny,allow

allow from all

The third step is to modify the hosts file

127.0.0.1 test.com www.test.com

127.0.0.1 aa.com www.aa.com

ok completed

The above introduces the xampp configuration virtual host, including the content. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template