I'm trying to create a folder named week7 and an html page named hello.html in that folder outside the document root and have it viewed through an Alias directive.
I created a folder named week7 out of the Document Root. I chose this location for it:
/usr/local/www/week7
while my document root is:
/usr/local/www/apache22/data
in httpd.conf and under tag, I wrote:
Alias /week7 /usr/local/www/week7 <Directory /usr/local/www/week7> Require all granted </Directory>
After rebooting the server, I got the following message: Forbidden 403 message.
I tried changing permissions for the hello.html file, the week7 folder and even the www folder and nothing changed.
Any ideas?
A 403 error occurs when a server won't allow you to access a webpage. You can't always fix a 403 error on your own, but simple tricks like refreshing your page or clearing your cache could help. If visitors to your webpage are getting 403 errors, you may have to reconfigure it.
If you're using apache 2.4
Order allow,deny
Allow from all
becomes...
Require all granted
https://httpd.apache.org/docs/2.4/upgrading.html
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