WordPress.org

Ready to get started?Download WordPress

Forums

WP Retina 2x
[resolved] How to Force Load Retina Image? (9 posts)

  1. forgetcomputers
    Member
    Posted 1 year ago #

    I'm using a custom WordPress template at http://robotcloud.net so I manually uploaded a @2x image (the Forget Computers logo and type in the lower right corner).

    This works great -- but only if I delete the standard image (then the @2x image loads). However, if I leave the standard image in place then the @2x image never loads (testing on an iPad 3 and iPhone 5).

    So I can either show all standard or all @2x, but can't seem to get the @2x to load if both are present. Any thoughts? Thanks!

    http://wordpress.org/extend/plugins/wp-retina-2x/

  2. Jordy Meow
    Member
    Plugin Author

    Posted 1 year ago #

    The problem might be something else, this is weird and doesn't make sense from the plugin perspective. It is impossible it would pick the @2x if the normal one is not present, it can only be the other way around.

    Are you using the Client Method or the Server Method? Then can you enable the plugin + use the Client Method + make all the images available (retina and non retina) and give me the URL?

  3. forgetcomputers
    Member
    Posted 1 year ago #

    Wow, fast response Jordy. Thanks!

    I was using Sever side, so I changed it to client side. That is the setting now and both images are active, although the problem appears to still exist.

    Previously as a double check, after deleting the standard version (@2x still working!) I turned OFF the plugin and only then did I get a missing image.

    The image URLs are http://robotcloud.net/images/logo-forget@2x.gif and http://robotcloud.net/images/logo-forget.gif

    Thanks again,

  4. Jordy Meow
    Member
    Plugin Author

    Posted 1 year ago #

    Would you mind enabling the Debug Mode as well? I don't have a Retina Device with me right now :)

  5. forgetcomputers
    Member
    Posted 1 year ago #

    Debug mode is now on.

  6. forgetcomputers
    Member
    Posted 1 year ago #

    Even in debug mode I can't get the @2x version to load unless I delete the standard version.

  7. Jordy Meow
    Member
    Plugin Author

    Posted 1 year ago #

    The script is not present in the code... weird!

    The HTML code seems to be extremely simple so I wonder if the theme you are using is not avoiding to include all the standards functions of WordPress Theme API. One of them includes all the scripts required, and of course the plugin is using this feature...

    In your Theme files, in the header you need a call to wp_head:
    http://codex.wordpress.org/Function_Reference/wp_head

    Then in your footer, you need a call to wp_footer():
    http://codex.wordpress.org/Function_Reference/wp_footer

    Let me know if that resolves the issues.

  8. forgetcomputers
    Member
    Posted 1 year ago #

    Hi Jordy,

    Those calls appear to already be there (nothing to add). Sounds like I need to turn this over to our web developer. I'm sure he can figure it out -- or work with you more adeptly than I can.

    Thanks for your quick responses!

  9. Jordy Meow
    Member
    Plugin Author

    Posted 1 year ago #

    Maybe you could ask your web developer, but yes, indeed, the scripts added by my plugin are not loaded here for some reason, and since the code is so clean and tiny, I suspect there is something going on here (maybe the header and footer theme pages aren't called at all, that's also a possibility).

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.