Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

403 forbidden: permission to access images

I'm currently building a new version of a site in Wordpress and trying to add a few images as normal to be referenced both by CSS & HTML. Weirdly it's allowed me to add several images like the logo etc yet when I try to add a few more images it's giving the forbidden message below. The image doesn't appear either and the forbidden message below shows when I goto the path of the image.

Forbidden

You don't have permission to access /v2/wp-content/themes/default/images/contact-yellow-icon.png on this server. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

I've never had this problem before out of the several other WP sites I've setup. What could be the problem?

If I put in the path to another image then it works fine (http://www.domain.com/v2/wp-content/themes/default/images/contact-innovation-logo.png) so don't know why it won't allow me to access the other images!?

like image 710
Rob Avatar asked Feb 07 '12 09:02

Rob


People also ask

What causes 403 Forbidden?

The 403 Forbidden error appears when your server denies you permission to access a page on your site. This is mainly caused by a faulty security plugin, a corrupt . htaccess file, or incorrect file permissions on your server.

What does 403 restricted access mean?

The 403 Forbidden error is an HTTP status code which means that accessing the page or resource you were trying to reach is absolutely forbidden for some reason. This article contains basic troubleshooting instructions for how you can identify and resolve a 403 Forbidden error.


1 Answers

you should check file permissions for /v2/wp-content/themes/default/images/contact-yellow-icon.png

i think they should be 644 so that all can read that file

or you can check file permissions of /v2/wp-content/themes/default/images/contact-innovation-logo.png

you can change permissions with ftp manager or with shell

** updated by Eric Leroy if file permissions 644 does not work, change to 755 that is what I used to fix the issue. If you are not familiar on how to do this on *inx based, and mac systems, here is how: Open terminal and navigate to the parent folder of the images. type sudo chmod -R 775 (then type the name of your images folder after 775 ) it will ask you for your password, then your images will work on your website.

like image 111
Kirill Bubochkin Avatar answered Sep 17 '22 17:09

Kirill Bubochkin