Access forbidden! using xampp on macosx 10.5

13,099

Solution 1

Check in the httpd.conf for the block of code. By default on a mac it's pretty restrictive. If it's only local and you don't care to much you can open it up like:

<Directory />
    Options All
    AllowOverride All
    Order deny,allow
    Allow from all
</Directory>

That might help, or, could be the file permissions themselves. The /var/log/apache2/error_log and /var/log/apache2/access_log may also give you a bit more detail as to what's going on.

Solution 2

The most common reason that I experience this problem (and I believe that this is one of the most common causes of this problem in *nix systems in general) has to do with the permissions system of Mac's underlying Unix, which makes sense as 403 is a permissions error (thus the message It is either read-protected or not readable by the server.). It's caused by the fact that Mac is listing you as the creator of the file and denying others from being able to even read it.

Easiest way to fix this from the commands like is chmod -R 666 /Applications/XAMPP/htdocs. That will give read/write permissions to everything under XAMPP's document root. (Of course, you can also do this through the File>Get Info menu in the Finder).

Share:
13,099

Related videos on Youtube

LCHawk
Author by

LCHawk

Updated on September 17, 2022

Comments

  • LCHawk
    LCHawk over 1 year

    I installed xampp back around January 2009, and CF8 to test coldfusion on my macbook (note: I do not think that this issue is related to CF, but only xampp). I only ever used the apache part of xampp, and this was working for over a year.

    In the last couple of months at the most I've started getting the following error message (even for none CF sites, and non .cfm pages, the error occurs for .html files..):

    Access forbidden!

    You don't have permission to access the requested object. It is either read-protected or not readable by the server.

    If you think this is a server error, please contact the webmaster

    Error 403

    erikvold.lan

    Sun Mar 21 20:58:45 2010

    Apache/2.2.11 (Unix) DAV/2 mod_ssl/2.2.11 OpenSSL/0.9.7l PHP/5.2.9 mod_perl/2.0.4 Perl/v5.10.0

    As far as I recall I haven't made any change, so it's like it was working for a year then just stopped working..