Top丶小倩
Top丶小倩Lv1
刚配Apache虚拟主机搞了一下午,总算搞明白了!

在httpd-vhosts.conf里要写ServerName和DocumentRoot,目录权限要用Require all granted,之前没加这个一直403报错,可给我整崩溃了...

<VirtualHost *:80>
    ServerName test.local
    DocumentRoot "D:/phpstudy/WWW/test"
    <Directory "D:/phpstudy/WWW/test">
        Require all granted
    </Directory>
</VirtualHost>


#Apache配置学习#