0
点赞
收藏
分享

微信扫一扫

phpstudy You don't have permission to access /phpinfo.php on this server.

代码小姐 2022-07-12 阅读 73

You don’t have permission to access /phpinfo.php on this server.
这个问题只有在高版本的php中才出现,5.6及以下都不会出现。
修改前:

<VirtualHost *:80>
ServerName xxx.com
DocumentRoot D:/phpStudy/WWW/xxx
<Directory "D:/phpStudy/WWW/xxx">
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Require local
</Directory>
</VirtualHost>

修改后:

#第二个主机
<VirtualHost *:80>
ServerName 192.168.0.xxx
ServerAlias bcclearnning.com
DocumentRoot D:\phpStudy\WWW\bcc_service
<Directory "D:\phpStudy\WWW\bcc_service">
Options FollowSymLinks ExecCGI
AllowOverride All
Order allow,deny
Allow from all
Require all granted
</Directory>
</VirtualHost>
#如果需要添加更多,继续写就行了!ServerAlias 设置别名

问题得到解决!


举报

相关推荐

0 条评论