Support » Plugin: Really Simple SSL » Mixed content filter not working with Autoptimize plugin

  • Resolved supamike

    (@mikeingz)


    Hello,

    Really Simple SSL works great on my website, except when I try to use Autoptimize ( https://wordpress.org/plugins/autoptimize/ ).

    I’ve got some mixed content problem for some links.
    To solve it I have to disable the “Optimize HTML Code” and “Optimize CSS Code” options, but then the plugin becomes quite useless.

    I am going to try another cache plugin to test it.

Viewing 10 replies - 1 through 10 (of 10 total)
  • did you, under wordpress’ general settings, change your site- and wordpress-URL to the HTTPS-one as well? AO uses these internally, so if these aren’t updated you’re bound to run into issues.

    else you can try setting AO’s CDN URL to your HTTPS-url (or try a protocol-relative CDN URL).

    if that doesn’t help let me know (with the URL where I can see what’s happening) and I’ll have a quick look.

    frank (ao’s developer)

    Yes my general settings are good, and I tried the CDN option but it doesn’t change anything.

    Optimize HTML Code and Optimize CSS Code have been enabled again, and I got some mixed content errors on this page :
    https://www.supadezign.com/
    And all external links have https instead of http ( see here, for the “Visit the website” button : https://www.supadezign.com/portfolio/weyes-clothing/ ).

    My htaccess file has been updated properly, and as I said, everything works fine without AO.

    Plugin Author RogierLankhorst

    (@rogierlankhorst)

    The mixed content fixer is active on those pages, so it’s doing it’s job. But it does not edit css files. The autoptimize plugin has some http links cached in a css file wp-content/cache/autoptizime/css. If you clear the cache, or delete the cached files, then regenerate, your problem might be solved.

    I think what happens, is that when autoptimize is not active, that url is located in the websource, so the mixed content fixer can fix it automatically. When you activate autoptimize, it starts using the cached css file with the http link.

    I have deleted the cache already (manually), several time, and it still doesn’t solve the problem.
    That’s why it’s pretty weird…

    Plugin Author RogierLankhorst

    (@rogierlankhorst)

    Maybe the plugin does not generate the url from the WP siteurl, but straight from the original websource.

    In that case, you need to tackle the original cause: this background image is probably inserted by a theme setting. If you re-save those settings, or re-insert the image, that could fix the problem at the root.

    can’t investigate immediately, but what kind of files are still on HTTP? background-images? fonts? something else?

    ok, so I see

    
    .archive{background-image:url(http://www.supadezign.com/wp-content/uploads/2015/08/background5.png) !important;

    so can you set the CDN in Autoptimize to //www.supadesign.com and clear all caches (page cache & AO cache)?

    frank

    Actually I am using Visual Composer ( https://vc.wpbakery.com/ ) and I did solve the problem by re-inserting the background images in the settings and saving the page.

    It works fine for the homepage now, but all the external links are still converted into https :
    https://www.supadezign.com/portfolio/weyes-clothing/ (the Visit the website button).

    I even tried to exclude a url from the mixed content fixer with your function rsssl_exclude_http_url($html) but it still doesnt work…

    Any idea ?
    Thank you very much

    Plugin Author RogierLankhorst

    (@rogierlankhorst)

    The mixed content fixer is specifically designed not to replace external links to https. Can you deactivate the mixed content fixer to see if the issue then goes away? In SSL/settings, you can disable the mixed content fixer while staying on SSL.

    If it doesn’t go away, then another plugin is changing your url to https.

    I have deactivated it and it works well now.
    Only the links for the tag pages are still in http but it’s fine, it’s automatically redirected in https.
    At least I don’t have mixed content anymore and my external links are fine.

    Thank you very much for your great support

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Mixed content filter not working with Autoptimize plugin’ is closed to new replies.