我在Mac上的XAMPP中配置apache主机名和virtualhost。
但是,当我访问主机URL时,xampp将我重定向到/ dashboard:mydomain.dev/dashboard
这是我的httpd-vhosts.conf:
# Virtual Hosts
<VirtualHost *:80>
DocumentRoot "/Applications/XAMPP/xamppfiles/htdocs/web_frikinow/public"
ServerName mydomain.dev
</VirtualHost>
这是我的/ etc / hosts文件:
##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting. Do not change this entry.
##
127.0.0.1 localhost
255.255.255.255 broadcasthost
::1 localhost
127.0.0.1 mydomain.dev
127.0.0.1 Funny-Frontend # added by Apache Friends XAMPP
有什么问题吗?
解决方案是在文件httpd.conf中取消注释该模块:
# Virtual hosts
Include etc/extra/httpd-vhosts.conf
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句