Results 1 to 9 of 9
  1. #1
    Join Date
    Apr 2020
    Location
    Scotland
    Posts
    29
    Plugin Contributions
    0

    Default 403 forbidden error when trying to view or link to images?

    Hello,

    I am trying to link to an image in my zencart images folder and keep getting a 403 forbidden error. I am not too clued up on zencart but from searching online it looks like this could be a folder permission error.

    The attached images show more:

    Click image for larger version. 

Name:	Image - exists in folder.jpg 
Views:	104 
Size:	29.6 KB 
ID:	20098
    Click image for larger version. 

Name:	Image - 403 Error.jpg 
Views:	109 
Size:	31.0 KB 
ID:	20099
    Click image for larger version. 

Name:	Image - Missing External Site.jpg 
Views:	108 
Size:	29.6 KB 
ID:	20100
    Click image for larger version. 

Name:	Image - Current Permissions.png 
Views:	105 
Size:	22.9 KB 
ID:	20101

    First screenshot shows images is showing on ftp in my images folder - /images/ad-aquamarine.jpg
    Second screenshot shows the 403 error I get when I try to view this image on chrome
    Third screenshot shows the weird 'broken image' icon I get when trying to link to image from my forum website
    Fourth screenshot shows current folder permissions

    It is definitely a website or server settings as is happening on many different websites with all my images and I can link to other random images (not hosted by me) without issue. If it is a permissinos error what should I change it too and would this still be save from hotlinking and spammers/hackers etc?

    If not, can anyone suggest a good (preferably) free place to host images that I can link to in my blog, forum etc?

  2. #2
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,705
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    Not a good idea to name an image with "ad" in name. I recently had a client put up a bunch of them named similarly and the browser automatically made them disappear (brave browser).
    Mike
    GeekHost - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

  3. #3
    Join Date
    Feb 2009
    Location
    UK
    Posts
    1,065
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    It could be that your /images/.htaccess has been changed - might be worth checking it against the original. Although, if as you say it's happening on many different websites then it sounds like a server configuration issue.
    Simon

  4. #4
    Join Date
    Apr 2020
    Location
    Scotland
    Posts
    29
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    Quote Originally Posted by barco57 View Post
    Not a good idea to name an image with "ad" in name. I recently had a client put up a bunch of them named similarly and the browser automatically made them disappear (brave browser).
    That is just an old tester product - I learnt that google likes a proper name so these were all changed to better etxt, in this case adore aquamarine hair dye

  5. #5
    Join Date
    Apr 2020
    Location
    Scotland
    Posts
    29
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    Quote Originally Posted by simon1066 View Post
    It could be that your /images/.htaccess has been changed - might be worth checking it against the original. Although, if as you say it's happening on many different websites then it sounds like a server configuration issue.
    Thanks - I have contacted my webhosts as never had this issue before I moved to them so hopefully is just a permission issue.

  6. #6
    Join Date
    Apr 2020
    Location
    Scotland
    Posts
    29
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    HI,
    Got the following reply from my webhosts:
    In the main .htaccess file for the website, lines 190 - 319 contain a big list of rewrite conditions. It's these conditions that are causing the image file to be forbidden. Who is responsible for creating this code? I think it might be intended to prevent hotlinking but it would be best to check
    I have added the htaccess file info below as no idea if these are to prevent hotlinking or not. Can I remove and will it allow hotlinking?

    PHP Code:
    RewriteCond %{HTTP_REFERER} !^http://beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://funkyears.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://funkyears.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://funkyears.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://funkyears.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyeforum.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyeforum.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyeforumcouk.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyeforumcouk.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallery.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallery.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallery.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallery.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallery.com/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallery.com$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallerycom.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://hairdyegallerycom.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://manicpanichairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://manicpanichairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://manicpanichairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://manicpanichairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://specialeffectshairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://specialeffectshairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://specialeffectshairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://specialeffectshairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://tartandiva.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://tartandiva.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://tartandiva.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://tartandiva.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://upgrade.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://upgrade.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.funkyears.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.funkyears.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.funkyears.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.funkyears.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyeforum.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyeforum.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyeforumcouk.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyeforumcouk.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallery.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallery.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallery.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallery.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallery.com/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallery.com$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallerycom.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.hairdyegallerycom.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.manicpanichairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.manicpanichairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.manicpanichairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.manicpanichairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.specialeffectshairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.specialeffectshairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.specialeffectshairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.specialeffectshairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.tartandiva.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.tartandiva.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.tartandiva.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.tartandiva.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.upgrade.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^http://www.upgrade.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://funkyears.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://funkyears.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://funkyears.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://funkyears.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyeforum.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyeforum.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyeforumcouk.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyeforumcouk.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallery.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallery.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallery.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallery.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallery.com/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallery.com$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallerycom.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://hairdyegallerycom.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://manicpanichairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://manicpanichairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://manicpanichairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://manicpanichairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://specialeffectshairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://specialeffectshairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://specialeffectshairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://specialeffectshairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://tartandiva.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://tartandiva.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://tartandiva.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://tartandiva.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://upgrade.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://upgrade.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.funkyears.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.funkyears.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.funkyears.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.funkyears.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyeforum.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyeforum.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyeforumcouk.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyeforumcouk.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallery.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallery.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallery.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallery.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallery.com/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallery.com$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallerycom.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.hairdyegallerycom.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.manicpanichairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.manicpanichairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.manicpanichairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.manicpanichairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.specialeffectshairdye.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.specialeffectshairdye.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.specialeffectshairdye.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.specialeffectshairdye.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.tartandiva.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.tartandiva.beeunique.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.tartandiva.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.tartandiva.co.uk$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.upgrade.beeunique.co.uk/.*$      [NC]
    RewriteCond %{HTTP_REFERER} !^https://www.upgrade.beeunique.co.uk$      [NC]
    RewriteRule .*\.(jpg|jpeg|gif|png|bmp)$ - [F,NC

  7. #7
    Join Date
    Apr 2020
    Location
    Scotland
    Posts
    29
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    Hi, No idea why my replies are not showing up - but instead of adding php text i'll add the htaccess file as a screenshot instead.

    My hosting company say these lines are causing the image issue but they dont want to remove them as they may be stopping hotlinking - is it ok to remove these lines and if so will I still be safe from hotlinking?

    Thanks for any help

    Click image for larger version. 

Name:	Screenshot (921).jpg 
Views:	21 
Size:	69.0 KB 
ID:	20108

  8. #8
    Join Date
    Apr 2020
    Location
    Scotland
    Posts
    29
    Plugin Contributions
    0

    Default Re: 403 forbidden error when trying to view or link to images?

    Hi,
    Can anyone tell me if its ok to remove these lines from htaccess? I dont know if this is to block hotlinking or not, but right now I cannot link to any images on my website and I really need to be able to.

    Thanks if you can help

  9. #9
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    8,672
    Plugin Contributions
    9

    Default Re: 403 forbidden error when trying to view or link to images?

    Those are old (Apache 2.2) entries to result in a 500 error when linking from the URL listed.

    IOW hotlinking but interesting that it would be set to prevent hotlinking from your own site. That could be the problem.

    I would start by commenting out the lines in the .htaccess that list your site and the .jpg files.

 

 

Similar Threads

  1. v155 Forbidden error 403 when downloading
    By HeleneWallis in forum Managing Customers and Orders
    Replies: 4
    Last Post: 6 Dec 2016, 02:33 PM
  2. 403 Forbidden error when updating product
    By pinixdesign in forum Setting Up Categories, Products, Attributes
    Replies: 28
    Last Post: 27 Mar 2012, 05:10 AM
  3. '403 Forbidden Error' when trying to download product
    By rlfreshwater in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 13 Sep 2008, 08:45 PM
  4. 403 forbidden error when trying to access admin
    By jsiperko in forum Basic Configuration
    Replies: 1
    Last Post: 13 Jun 2006, 02:56 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR