I have this project in PHP. The whole project is fine except when I browse to index.php on localhost, it me sends this error?
2 Answers
Sounds like a permissions error. Try sudo chmod -R 775 on the directory in question. (Preferably where the site's root folder is).
As well, use sudo nano /etc/apache2/sites-available/000-default.conf to open nano and enter this at the bottom of the file (keep in mind that [folder name] is your root folder for the site.
<Directory [folder name]> AllowOverride All </Directory>
- 126
I would check permissions, but also your configuration settings in apache.
There were a couple changes in how to allow permissions to your directory or project, which if the project was started under apache2.2 it would take some updating.
To sum up one of the big gotchas: (quoted from linked site, emphasis added)
Here are some examples of old and new ways to do the same access control.
In this example, there is no authentication and all requests are denied.
2.2 configuration:
Order deny,allow
Deny from all
2.4 configuration:
Require all denied
In this example, there is no authentication and all requests are allowed.
2.2 configuration:
Order allow,deny
Allow from all
2.4 configuration:
Require all granted
Check those out as well as your directory permissions (making sure your web server user can access all directories in the path to this folder).
- 746
