我的本地开发机器上需要几个虚拟主机。不幸的是,它需要是窗户。
httpd-vhost.conf
<VirtualHost *:80>
ServerAdmin mateusz.tracz@vd.pl
DocumentRoot "C:/xampp/htdocs"
ServerName localhost
</VirtualHost>
<VirtualHost *:80>
ServerAdmin mateusz.tracz@vd.pl
DocumentRoot "C:/xampp/htdocs/manadom.local/public"
ServerName manadom.local
ErrorLog "logs/manadom.local-error.log"
CustomLog "logs/manadom.local-access.log" combined
</VirtualHost>
<VirtualHost *:80>
ServerAdmin mateusz.tracz@vd.pl
DocumentRoot "C:/xampp/htdocs/galeriabiznesu"
ServerName gb.loc
ErrorLog "logs/gb.loc-error.log"
CustomLog "logs/gb.loc-access.log" combined
</VirtualHost>
和主机文件:
127.0.0.1 localhost
127.0.0.1 manadom.local
127.0.0.1 gb.loc
问题是:localhost指向
C:/xampp/htdocs/manadom.local/public
manadom.local 指向
C:/xampp/htdocs/manadom.local/public too
gb.loc 指向
C:/xampp/htdocs/manadom.local/public
我不知道怎么了?
请帮助我,我不是管理员,但我读了很多,我不知道我可能会做错什么。