apache配置虚拟主机方法

作者:袖梨 2022-06-25

如果你安装的是 wamps教程erver 集成的   那你就进入wampbinapacheapache2.2.11confextrahttpd-vhosts.conf 配置文件

进行如下配置: 意思是配置3个虚拟主机 ,分别是

1  website.localhost:8080  c:usersn.zhangdocumentswebsitedhr3

2  tools.localhost:8080    c:usersn.zhangdocumentstools

3  test.localhost:8080    c:testphp教程public

//////////////////////////////

  servername website.localhost

    serveradmin [email protected]

    documentroot "c:usersn.zhangdocumentswebsitedhr3"

 

  options indexes multiviews followsymlinks

  allowoverride all

  order allow,deny

  allow from all

 

 

    errorlog "logs/test.tools.directhr.net-error.log"

    customlog "logs/test.tools.directhr.net-access.log" common

 

  servername tools.localhost

    serveradmin [email protected]

    documentroot "c:usersn.zhangdocumentstools"

 

  options indexes multiviews followsymlinks

  allowoverride all

  order allow,deny

  allow from all

 

 

    errorlog "logs/test.tools.directhr.net-error.log"

    customlog "logs/test.tools.directhr.net-access.log" common

 

  servername test.localhost

    serveradmin [email protected]

    documentroot "c:testphppublic"

 

  options indexes multiviews followsymlinks

  allowoverride all

  order allow,deny

  allow from all

 

 

    errorlog "logs/test.tools.directhr.net-error.log"

    customlog "logs/test.tools.directhr.net-access.log" common

还有件重要的事情是配置c:windowssystem32driversetchosts

相关文章

精彩推荐