PHP Using PHP with MySQL Limiting Records in SQL Queries Using LIMIT with Descending Order

durul dalkanat
durul dalkanat
62,690 Points

Forbidden. You don't have permission to access /shirts/ on this server.

Hello,

I am using Mac O.S X and MAMP Pro. When I clicked shirts button. Web page gives error message "Forbidden You don't have permission to access /shirts/ on this server. "

Another buttons work perfectly. I could not find my problem ?

thanks

3 Answers

Andrew Shook
Andrew Shook
31,709 Points

Check to ownership and permissions of the file that servers up the shirts page.

durul dalkanat
durul dalkanat
62,690 Points

Hello , which directory should I change permissions or ownership ? because I checked everything htdocs folder's sharing & permissions. everyone can read & write.

best regards

If shirts isn't a directory

then you need to make sure that its a valid url, maybe it's a slug generated by your application.

Josh Torres
Josh Torres
8,945 Points

Sometimes you need to change the User and Group settings in your httpd.conf. I am not sure where that file is in MAMP Pro but it should be easy to find. It holds the configuration settings for the Apache server in MAMP. For my httpd.conf, I change the code below:

#User _www
#Group _www

User Josh
Group staff

I changed the User from _www to Josh, which is my user account name on my computer. Then I changed the Group to staff, which is generally the group that you will need to put.

Hope this helps!