3

I just activated SSL on a website which also uses Visual Composer. I'm using the Really Simple SSL plugin for that. Everything seems to be set up fine but I still don't have the green padlock but the https is grey.

So I tried to figure out what's wrong and found that there are mixed content problems with some Visual Composer images. It says:

Mixed Content: The page at 'https://www.websitename.com/' was loaded over HTTPS, but requested an insecure image 'http://www.websitename.com/wp-content/visualcomposer-assets/elements/singleImage/singleImage/public/loading.gif'. This content should also be served over HTTPS.

The same problem also occurs for close.png, preview.png and next.png of Visual Composer.

How can I fix this? I searched online but couldn't find a solution yet. I use the latest Version of WordPress (4.9.5) and Visual Composer ran an update to 2.4.

Thanks for your help!

Steffi
  • 31
  • 1
  • 5

2 Answers2

0

Honestly, the easiest solution to Mixed Content errors in WordPress is to use the Really Simple SSL plugin once you first get your SSL.

Make sure your website URLs in your General Settings are updated to include https:// as well.

If you're still getting these issues, consider the SSL Insecure Content Fixer plugin.

Alternatively, you can also do a "real time find/replace" to replace http:// with https:// by adding something like the following to your functions.php file:

function steffi_live_find_replace( $buffer ){
    if( is_ssl() ) $buffer = str_ireplace('http://', 'https://', $buffer);
    return $buffer;
}

add_action( 'template_redirect', function(){
    ob_start();
    ob_start( 'steffi_live_find_replace' );
});

I'd recommend the first two plugins before I'd recommend the find and replace method. I'd be willing to wager you just don't have a setting tweaked quite right to secure all URLs and those plugins should help and are about as light-weight as you can get.

Xhynk
  • 13,513
  • 8
  • 32
  • 69
  • thanks for your answer. I am already using the Really Simple SSL plugin and all other links seem to be fine. The website URLs in General Settings are also set to https. I tried the SSL Insecure Content Fixer but it didn't help, unfortunately. Also not on the "highest" settings. The problem is just caused by the pictures of Visual Composer. I haven't tried the find/replace suggestion yet. Will do this when really nothing else works. I'd rather like to fix this on the plugins side. :/ my Really Simple SSL settings look like this http://prntscr.com/jd44tp – Steffi May 03 '18 at 08:52
0

Just want to mention that updating to the latest version of Visual Composer (v17.1.0 as of writing) fixed this for me.

gmolau
  • 2,815
  • 1
  • 22
  • 45