Apache配置虚拟主机后,不能访问localhost的问题
1、先在httpd-vhosts.conf设置好虚拟域名localhost <VirtualHost _default_:80> DocumentRoot "C:\phpStudy\WWW" ServerName localhost </VirtualHost>

3、别忘了查看hosts文件里是否绑定 localhost指向127.0.0.1,一般情况下会存在

1、先在httpd-vhosts.conf设置好虚拟域名localhost <VirtualHost _default_:80> DocumentRoot "C:\phpStudy\WWW" ServerName localhost </VirtualHost>
3、别忘了查看hosts文件里是否绑定 localhost指向127.0.0.1,一般情况下会存在