Huge problem with https when using Muffin Recent Posts

Hi, I'm having difficulties with the padlock on our website https://www.onestopmap.com.
In the footer I use the 'Muffin Recent Posts'. All the small featured images of the posts are loaded through http instead of https. Except for the first one, there the image source is loaded through https. When I add a post the image that first was loading through https moved to position 2 in the list and then gets loaded through http. I'm deactivating this for now, but I hope that can be fixed very soon.
Here some screenshots:
Thanks,
Koen.

Comments

  • Hi Koen,

    we have checked this and everything is fine. This item works with https properly. Probably the problem is because you had uploaded images into media not from https section. In this case we recommend to remove all media and upload images from https section.
  • Well, I have already done that. Although all my images were uploaded through https. So I have removed them entirely and uploaded them once again. Problem stays exactly the same. The first one in 'Muffin Recent Posts' is https, the others are http.

    Opening a blog post where I have 'Muffin Recent Posts' in the sidebar, the only images loaded through http are the second and further ones in 'Muffin Recent Posts'. Even the big featured image of the blog post is https. The same thumbnail of that image in 'Muffin Recent Posts' is http.

    Here you can see it in action:

    If you say the problem is not in the theme, I don't know what to do anymore. Maybe recreate the entire blog posts all over?

    I have just upgraded to your latest theme version just minutes ago.


  • For your interest, I am not using a plugin like Wordpress-https, because it slows down a lot. Maybe you have this plugin installed?
  • Please try to re-create blog posts and check if this will help. If not, then please send us access to your wp dashboard and FTP on pm and we`ll have a look on it. But as we wrote, we tested it also on our side and it works properly.
  • Hi, I've solved it myself, there is a bug in wordpress when using wp_get_attachment_url. It sometimes returns http instead of https. I've added following code to functions.php and everything is https:
    # Correct SSL Bug
    function correct_url_ssl($url)
    {
    if( function_exists('is_ssl') && is_ssl() )
    {
    return str_replace('http://', 'https://', $url);
    }
    return $url;
    }
    add_filter('wp_get_attachment_url', 'correct_url_ssl');

  • We`ll test this function soon on our side. But we tested default theme with ssl and works fine on our side and we had no idea what this could be. But if this function will work properly then we`ll add it with next update.

    Thanks!
Sign In or Register to comment.