I keep getting Access Forbidden Error 403 when I try running my installation of XAMPP on my MAC
I am running the project outside of /Applications/XAMPP/htdocs
. It's in my /Users/my_user_name/Projects/
directory.
Every time I try and go to my virtualhost I get a 403 error: Access forbidden.
I have edited my httpd-vhosts.conf file and I have allowed Virtual hosts in httpd.conf.
I have also set the User and Group to User my_user_name and Group Admin in httpd.conf
I even tried chmoding all my files and directory 777 but I still get Access forbidden.
I have also change Deny to Allow in the httpd-xampp.conf file in the new security settings.
The erro_log provided by XAMPP doesn't mention the 403 error I do see it in my access log as 127.0.0.1 - - [21/Aug/2013:14:45:20 -0400] "GET / HTTP/1.1" 403 1034
I turned on errors and I am seeing this [authz_core:error] [pid 52813] [client 127.0.0.1:57473] AH01630: client denied by server configuration:
Not sure what else to check or try. Please help lol.
Although XAMPP error 403 can be annoying, it's easy to solve whether you're using Windows, macOS, or Linux. All you have to do is edit the XAMPP httpd-xampp. conf file to ensure that everyone has access to phpMyAdmin. Then the 403 error should disappear right away.
Create Virtual Host First, you need to navigate to D:\xampp\apache\conf\extra or wherever your XAMPP files are located. In my case, my XAMPP file is located in drive D. Then, edit httpd-vhosts. conf with any text editor.
Just to have the answer right here:
You can permit access by adding Require all granted
to each VirtualHost
in your httpd-vhosts.conf:
# VirtualHost for my.site.com
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot "/Users/me/www/my.site.com/"
ServerName my.site.com
<Directory "/Users/me/www/my.site.com">
ServerSignature Off
Options Indexes FollowSymLinks IncludesNoExec
AllowOverride All
#Order allow,deny <- You can remove this
#Allow from all <- and that
# Insert the following:
Require all granted
</Directory>
</VirtualHost>
Good luck!
I kept having this 403 issue and could not find an answer UNTIL...
Curly (right and left) quotes where in my vhosts file.
If you see something like "xe2\x80\x9c" in your error log then this is your problem.
I opened the httpd-vhosts.conf file in a reliable editor (I used Dreamweaver) and noticed that the quotations are curly ones (left and right quotes). They need to be straight quotes. The regular text editor on my Mac would auto change any quotes I make to these curly ones and I wasn't noticing it.
Hopefully this answer will help someone.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With