• Resolved Adam Capriola

    (@adamcapriola)


    Hi Jordy, I noticed that retina images weren’t working for my new post today, so I turned on the debug and discovered that the wrong URL structure is being used to check for the retina images for any images I’ve uploaded since upgrading to WordPress 4.2:

    Here’s an example:

    2015-04-25 05:46:16: Retina file at '/var/www/html/si/sixprizes.com/wp-content/uploads/wp-content/uploads/2015/04/[email protected]' does not exist.
    2015-04-25 05:46:16: The img tag was not rewritten. No retina for 'https://sixprizes.com/wp-content/uploads/2015/04/m-venusaur-ex-xy-2-ptcgo-1-225x318.png'.

    You can see wp-content/uploads/ twice for the retina image check, which is wrong. I’m pretty sure this error began only after upgrading to WordPress 4.2 (I can’t recall making any other changes to my site).

    Also, I think WordPress started inserting https (rather than http) for images with 4.2 when define('FORCE_SSL_ADMIN', true); is included in wp-config.php (which I utilize). Not sure if that is having any effect. (Related patch.)

    https://www.ads-software.com/plugins/wp-retina-2x/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter Adam Capriola

    (@adamcapriola)

    To follow up, this is 100% related to the https change.

    WordPress 4.2 will insert images into content with https under the circumstances detailed above, which causes the invalid directory. I tried going into the HTML post editor and switching my image URL to http — and the retina version is now showing. If I change the location back to https and the image loses the retina treatment.

    So some kind of change needs to be made in regards to how the plugin handles https images.

    Ced

    (@cedriccharles)

    Same here !

    I’m also seeing a redundant “wp-content/uploads/” being added to the folder structure. This is only happening to image files stored in my theme folder.

    Eg:
    /wp-content/uploads/wp-content/themes/[theme name]/images/imagename.png

    Should be:
    /wp-content/themes/[theme name]/images/imagename.png.

    Ced

    (@cedriccharles)

    Yes, only for theme images too

    Plugin Author Jordy Meow

    (@tigroumeow)

    Please participate in this thread post only if it’s related to “https” like Adam Capriola explained it very well. I will look into this issue.

    For the theme image, please open a new thread, that will be easier for me to check when I am back (I am currently on holiday). Of course, if you have any workaround please let me and everyone know ??

    For a bit of explanation, the problem is bigger and more annoying to fix than it seems. The upload folder can be set to somewhere else, not under the WordPress root. I had to make this work first since all the images uploaded by the user go there.

    Now, for images NOT in the upload folder, the retina doesn’t work well I believe. For those images we need to check the “normal folder”. I need to do this ??

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Wrong directory structure being checked for retina files’ is closed to new replies.