Apache 403访问Mac OS X10.8上的本地主机时出现禁止的错误
我按照本教程在MacOSX10.8()上设置了Apache、MySql和PHP 当我转到“Localhost”时,出现以下错误:Apache 403访问Mac OS X10.8上的本地主机时出现禁止的错误,apache,permissions,osx-mountain-lion,Apache,Permissions,Osx Mountain Lion,我按照本教程在MacOSX10.8()上设置了Apache、MySql和PHP 当我转到“Localhost”时,出现以下错误: Forbidden You don't have permission to access / on this server. 当我去“Localhost/~benthompson”的时候,效果很好 当我完成教程的一半时,“Localhost”确实起作用了,但后来它停止了工作 可能是权限问题,但在哪里?要解决此问题,请检查此链接,阅读“丢失本地主机”部分 在htt
Forbidden
You don't have permission to access / on this server.
当我去“Localhost/~benthompson”的时候,效果很好
当我完成教程的一半时,“Localhost”确实起作用了,但后来它停止了工作
可能是权限问题,但在哪里?要解决此问题,请检查此链接,阅读“丢失本地主机”部分 在httpd.conf文件中启用vhost之后,会发生此错误。 通过取消对此行的注释:
Include /private/etc/apache2/extra/httpd-vhosts.conf
将此添加到httpd-vhosts.conf将解决您的问题。只需记住在这一个之前添加新的vhost:D
<VirtualHost *:80>
ServerName localhost
DocumentRoot /Library/WebServer/Documents/
</VirtualHost>
服务器名本地主机
DocumentRoot/Library/WebServer/Documents/
我希望这能解决你的问题