Site logo

Archived topic

Favicon https issue after theme migration

12 replies · Started by Edin on January 6, 2018

Viewing posts 1–13 of 13

I've migrated the theme from a test-site to a live site (which is on https).

Now I have the issue that the favicon is being loaded over http (therefore sabotaging my whole site https-wise):

Mixed Content: The page at 'https://mysite.com/' was loaded over HTTPS, but requested an insecure favicon 'http://mysite.com/wp-content/uploads/favicon.ico'. This content should also be served over HTTPS.

It worked before, so it has to be the theme.

I've re-uploaded all the images in the customizer after taking the theme live (also the "site icon").

What can it be?

The theme itself doesn't have any code related to the favicon - WordPress itself adds the HTML for the favicon using the site icon option in the Customizer.

Perhaps you have the favicon HTML added in GP Hooks?

No, I haven't, I've checked.

That's weird, I didn't have that problem with the old theme.

Tom, do you mind helping me out here, I'm a little desperate... having mixed content over the whole site is really not a good thing.

Thanks in advance!

Can you deactivate WP Rocket so I can see the source?

Tom, I've sent you an email with the site's login credentials, maybe it's easier that way to find the source.

I've spent the last three hours to find out what's causing the issue, all to no avail.

Thank you so much in advance!

Looks like you just needed to clear your WP Rocket cache. All is working now.

Thanks for taking a look Tom, but it's still showing mixed content (and I've cleared the cache at least 20 times since yesterday).

If you open an incognito Chrome you see it. It's also in the source code of the page...

Strange, my browser is giving me a green https symbol now.

The favicon loading is an .ico, but the site icon you've uploaded in the Customizer is a .png.

I wonder where that .ico is coming from? Perhaps a plugin you have installed is adding it in?

I have no idea. I went through the plugins I have, not sure which one it could be... The previous theme I've used (DIVI) had the option to add a favicon, maybe it's that? But why would it suddenly load over http when I switch to GP?

I've tried to delete it, and re-upload the site icon in the customizer, but that also didn't work.

Is there a way to find out WHAT is creating this insecure code?

Have you tried disabling your plugins one by one to see if one of them is causing it? You would have to disable your caching plugin first.

Something is adding the favicon.ico code to the header, you just need to disable things one by one until you find the culprit.

Found it!!! It was OptimizePress.

Thank you so much, Tom, for your help!!! I really appreciate it!

No problem :)

This archived topic is closed to new replies.