404 when fetching image from wp-content/uploads/

I get 404 status when fetching images, and the http still contains that image. Image shows up in a browser, but the 404 code breaks some applications.

calls to wp-content/uploads/ are redirected in .htaccess:

Read More
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteRule (.*) /index.php?getfile=$1 [L]
</IfModule>

Why do I get a 404 status if the image is in there and is served?

Related posts

Leave a Reply

2 comments

  1. Problem solved.

    The plugin “User Access Manager” was found guilty of inserting a .htaccess file into wp-content/uploads/ and not handling calls properly afterwards.

    I don’t know how UAM plugin could be fixed, but It’s ok to remove the .htaccess file. Nothing else depends on it. (at least in my case)

  2. Log in to your WordPress root directory and rename .htaccess to something like .htaccess_old. Next, login to your WordPress admin area and navigate to Settings -> Permalinks
    Next, choose a different permalinks structure from what you currently have and click the Save Changes button. Next, select the original permalinks structure you had and click the Save Changes button once more. Note, this will create a new .htacess file in your server. Fixes the images returning the 404 error. Cheers!