配置Xammp虚拟主机步骤(安装包版本win32-7.0.30-0-VC14)

1.在window系统路径C:\Windows\System32\drivers\etc\hosts中配置本地域名(hosts配置域名与IP的对应关系);


2.在appache配置文件httpd.conf中取消载入虚拟主机配置文件前的#。载入httpd.vhost.conf文件。 

3.在D:\LAMP\apache\conf\extra\httpd-vhost.conf中添加如下配置

<VirtualHost *:80>
    DocumentRoot "D:/proj"
    ServerName www.villiam
</VirtualHost>
<Directory "D:/proj">
    Options Indexes FollowSymLinks Includes ExecCGI
    AllowOverride All
    Require all granted

</Directory>


4.查看(在目标目录下创建测试proj,确认是否创建成功)




5.浏览器查看


猜你喜欢

转载自blog.csdn.net/pinming_sanlang1990/article/details/80923137