This topic has 17 replies, 3 voices, and was last updated 9 years, 11 months ago ago by Eva Kemp
Hi there-
We just launched https://www.thechocolatebunnyboutique.com and noticed in Firefox that we’re getting mixed content error for SSL.
I noticed this code in the head of site:
<style type=’text/css’>
@import url(http://fonts.googleapis.com/css?family=Open+Sans:400,800,300,700);@import url(http://fonts.googleapis.com/css?family=Lobster);@import url(http://fonts.googleapis.com/css?family=Dancing+Script);.subtitle_seagreen{font-size:22px; color:#647467;font-family:Lobster}.subtitle_seagreen2{font-size:24px; color:#647467;font-family:Dancing Script,Open Sans}.subtitle_yellow{font-size:22px; color:#ffc925;font-family:Lobster}.subtitle_white{font-size:22px; color:#fff;font-family:Lobster}.subtitle_white2{font-size:24px; color:#fff;font-family:Dancing Script,Open Sans}.subtitle_olive{font-size:22px; color:#8c8c71;font-family:Lobster}.title_olive{font-size:48px; color:#686726;font-family:Open Sans}.title_white{font-size:56px; color:#fff;font-family:Open Sans}.title_white2{font-size:56px; color:#fff; line-height:1; text-transform:uppercase;font-family:Georgia}.title_seagreen{font-size:48px; color:#647467;font-family:Open Sans}.title_seagreen2{font-size:60px; color:#647467; text-transform:uppercase;font-family:Georgia}.text_white{font-size:13px; color:#fff;font-family:Open Sans; text-align:center}
</style>
We don’t have those fonts set anywhere in any theme or plugin settings. We’ve used this theme before on other secure sites so didn’t think was theme but I can’t find where that code is coming from and if I google .title_seagreen2, the only other site that comes up also uses this theme.
I noticed this comment at themeforest:
jmprojeto PURCHASED 5 months ago
hello where i can change the script calls the google fonts from http to https. I’m using a security certificate that is sending alerts errors.
8theme AUTHOR 5 months ago
Hello, jmprojeto,
You may change that in this file: framework/theme-functions.php
and this ticket in the support forum:
https://www.8theme.com/topic/legenda-https-google-font/#post-24981
We use a child theme so need to know best route since site is now live and how to do in child theme rather than editing parent.
Thanks much-
Jesica
Hello,
You need create a folder “framework” with the file shortcodes.php in it.
Add the lines 1614, 1618 from the parent file and edit the link from http//fonts.googleapis.com/css?family to //fonts.googleapis.com/css?family
Refer to http://codex.wordpress.org/Child_Themes > paragraph “Referencing / Including Files in Your Child Theme”
Thank you.
Regards,
Eva Kemp.
k, we’re off a hair, is throwing errors.
tried
<?php
<link rel=’stylesheet’ href=’//fonts.googleapis.com/css?family=<?php echo $google_name; ?>’ type=’text/css’ media=’all’ />
//wp_enqueue_style($google_name,”//fonts.googleapis.com/css?family=”.$google_name);
?>
then tried JUST those lines
<link rel=’stylesheet’ href=’//fonts.googleapis.com/css?family=<?php echo $google_name; ?>’ type=’text/css’ media=’all’ />
//wp_enqueue_style($google_name,”//fonts.googleapis.com/css?family=”.$google_name);
and the 2nd line appears at top of front end of site.
thoughts?
Hello,
Please provide us with wp-admin panel and FTP credentials in Private Content.
Thank you.
Regards,
Eva Kemp.
Thank you. It’s a holiday weekend and everyone’s out til Monday so I can’t create ftp user but I did create a login.
Files can be edited here, theme is Chocolate Bunny.
https://www.thechocolatebunnyboutique.com/wp-admin/theme-editor.php
You’ll see functions.php and shortcodes file which IS in framework folder in theme.
[~/www/wp-content/themes/chocolate-bunny/framework]
I am not currently calling shortcodes.php via functions.php so the site doesn’t blow up.
Thanks again!
Hello,
Please remove the changes you made in the child theme concerning this issue and add this code in .htaccess file in the site directory:
<IfModule mod_headers.c>
Header set Access-Control-Allow-Origin "*"
</IfModule>
Thank you.
Regards,
Eva Kemp.
Hi there-
I’ve added that now. Still seeing the same line in head of site ( <style type=’text/css’>
@import url(http://fonts.googleapis.com/css?family……. ) and still getting mixed content message in Firefox.
Hello,
I’m unable to view your site now.
Have you removed SSL certificate?
Please show a screenshot where exactly you see those errors.
Thank you.
Regards,
Eva Kemp.
we had to remove that as it totally broke the site in Firefox.
Hello,
Is there any assistance required from us?
Thank you.
Regards,
Eva Kemp.
I think we’re good now. Had another dev at work help me track down. Ended up using https://wordpress.org/plugins/ssl-insecure-content-fixer/ b/c not everything would override via child theme. Somehow that plugin got it all… FF and IE both now not showing mixed content.
Thanks!
Hello,
We’re glad you’ve found the solution.
Have a nice day.
Regards,
Eva Kemp.
I have the same problem, I will try to addon. And hope it helps. But still, this issue should be fixed, there several insecure callings of URLs in the theme. Best would be to change to “//” or set an option in the setting like: Use SSL ?
Ok, tried this ssl plugin, it is working. Problem is: I use better minify, which won´t change the http to https ;( I can´t find for the sake of my life the file which creates this unsecure @import for the font.
Where is it? In which PHP file or modul? (In IDStore theme) I really need it to change…
Hello @Qefx,
This line @import url(http://fonts.googleapis.com/css?family=Open+Sans);
is placed in style.css file in the theme folder. Please check it.
Regards,
Eva Kemp.
Thank you! That drove me nuts!
Happy new year!
Hello @Qefx,
You’re welcome.
Happy New Year!
Regards,
Eva Kemp.
The issue related to '‘HTTPS Issue – Google Fonts and Mystery Code in head’' has been successfully resolved, and the topic is now closed for further responses