我有域名我想知道如何将域名连接到我的虚拟主机我是新的,所以请回答易于理解的答案感谢阅读并希望回答
我更改了热门文件C:\ WINDOWS \ system32 \ drivers \ etc
127.0.0.1 www.test.com
并且还更改httpd-vhosts.conf D:\ wamp \ bin \ apache \ Apache2.4.4 \ conf \ extra
ServerAdmin webmaster@test.org.in DocumentRoot" c:\ wamp \ www \ test" ServerName test.org.in ErrorLog" logs / test.org.in-error.log" CustomLog" logs / test.org.in-access.log"共同
答案 0 :(得分:1)
您可以使用 httpd-vhosts.conf 文件
这是一个小例子
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName www.mydns.local
ServerAlias www.mydns.local
DocumentRoot "E:\WWW_VM_SHARE\smarty_fe\public"
<Directory "E:\WWW_VM_SHARE\smarty_fe\public">
Options Indexes FollowSymLinks Includes ExecCGI MultiViews
Require all granted
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>