[英]Apache virtual subdomains
I'm trying to create virtual subdomains but apache fails to start after I edit the httpd-vhosts.conf and there are no errors in the error log. 我正在尝试创建虚拟子域,但是在编辑httpd-vhosts.conf后apache无法启动,并且错误日志中没有错误。
<VirtualHost 127.0.0.1:80>
ServerAlias *.localhost
UseCanonicalName Off
VirtualDocumentRoot C:/xampp/htdocs/%1
</VirtualHost>
Note: I'm running apache via xampp on windows. 注意:我正在Windows上通过xampp运行apache。
Struggled with the same problem a while ago. 前一阵子也遇到同样的问题。 You have to enable the vhost_alias module.
您必须启用vhost_alias模块。
In apache/conf/httpd.conf find this line and uncomment it 在apache / conf / httpd.conf中找到这一行并取消注释
#LoadModule vhost_alias_module modules/mod_vhost_alias.so
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.