在搭建windows lamp 环境时,其他步骤全部完成,但是在地址栏输入url时发现出现You don't have permission to access /index.php on this server.这个问题,后来才发现在切换PHP版本时出现的这个问题,解决问题的办法如下
- <VirtualHost *:80>
- DocumentRoot D:/wamp/www/aa
- ServerName localhost
- <Directory "d:/wamp/www/aa">
- Options Indexes FollowSymLinks ExecCGI
- Order allow,deny
- Allow from all
- AllowOverride All
- </Directory>
- </VirtualHost>
只要将红色部分的几个字符填写上去,就可以解决问题。
注意:切换PHP版本时出现这个问题是这样解决的。