WP Retina 2x
[resolved] Invalid image URL results in non-standard 404 errors (3 posts)

  1. Stanback
    Posted 3 years ago #

    I've noticed that when visiting an image URL that does not exist, the 404 error I receive from WP Retina 2x seems to only output the "not found" header rather than showing my WordPress page (which is what happens with the plugin deactivated).

    I've fixed this on my end by adding the following...

    RewriteCond %{REQUEST_FILENAME} -f

    Above the rewrite rule (in the WordPress .htaccess file)...

    RewriteRule ^.*\.(jpg|jpeg|gif|png|bmp) /wp-content/plugins/wp-retina-2x/wr2x_image.php [QSA,L]

    Is it possible/logical to incorporate this change in future versions? Thanks!


  2. Stanback
    Posted 3 years ago #

    You could also change how the plugin's code is handling the 404 error, but .htaccess was the simplest solution that didn't involve modifying the plugin.

  3. Jordy Meow
    Plugin Author

    Posted 3 years ago #

    Jeremy is the creator of Retina-Images, which is actually used here for the Server-Side method. I sent him a link to this thread, hopefully he will have an exact idea on this, even though you must be right :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP Retina 2x
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic