![Check out Enfold](https://kriesi.at/wp-content/themes/kriesi/images/banner-enfold.jpg)
-
AuthorPosts
-
October 10, 2013 at 11:10 pm #173852
We have a site that is mostly HTTP (and has to be for speed) with one page that is HTTPS.
That page is: https://livethelife.org/donate/Using any android mobile phone if you type in livethelife.org (before you even click on the “Donate” page) you get a big security warning with the error: “There are problems with the security certificate for this site. This certificate is not from a trusted authority.”
But we know the cert is fine because it works for other pages that are not related to Enfold under the same domain. This error stops users in their tracks and they are not likely to donate.You can easily reproduce the error if you have an Android phone. If not simply click here and test with the above URL:
https://www.manymo.com/emulators/88/connect (click the world icon to go to the web and test with “livethelife.org”)It works on all iPhones and iPads though beautifully, even the secure pages.
On the desktop however:
Using IE it gives an error at the bottom: “Only secure content is displayed”
Using Chrome it does not give an error but if you right click and choose “Inspect Element” and then click the “console” tab you will see 2 errors (it did have 4 but we got it down to 2). They are:The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.ttf.
(index):39
The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.svg..
(index):39So basically the main problem is that any user with an Android phone will most likely not visit our site because of that error. We think it may be related to the “fonts”.
Note: We have the latest framework that I know of which uses:
href="'.$prefix.'://fonts.googleapis.com/css?family='.str_replace(' ','+',$rule_split[0]).$font_weight.'" (found in the class-style-generator.php)
I know we can’t be the only one having this problem. Making the entire site SSL is not an option.
How do we fix this?Thanks
LTLOctober 12, 2013 at 10:35 am #174552Hello ltladmin!
Please update your theme to the latest version (2.3.2) and check if the update solves the issue. If not please create us an admin account and post the login credentials as private reply. I’d like to switch to another theme, deactivate the plugins, etc. to find the culprit.
Cheers!
PeterOctober 14, 2013 at 4:16 pm #175126Ok thanks for replying back. I will do this soon and let you know if that fixes it.
October 14, 2013 at 4:38 pm #175135Dude… what is the bst way to update to the latest version of Enfold? I don’t know where to get the latest version either (unless by default the downloadable file in my Themeforest account is updated to the latest automatically).
October 14, 2013 at 8:05 pm #175236Hi!
Please take a look at this video:
Cheers!
JosueOctober 16, 2013 at 8:16 pm #176594I am now upgraded to 2.3.2.
Unfortunately, the problem is still there. But now on the “Inspect Element” console I get this (using Chrome):
The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.woff?v=2.
(index):40
The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.ttf?v=2.
(index):40
The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.svg?v=2.
(index):40I truely believe that this is the problem. I just need the things above to AUTOMATICALLY be called according to what type of page your own (HTTP or HTTPS). Any idea?
October 18, 2013 at 7:51 am #177279Hi!
Please try to modify /wp-content/themes/enfold/config-templatebuilder/avia-template-builder/php/font-manager.class.php a bit. Open up the file and replace:
$fstring = $font_list['folder'].'/'.$font_name;
with
$fstring = $font_list['folder'].'/'.$font_name; if(!empty($_SERVER['HTTPS'])) { $fstring = str_replace('http://', 'https://', $fstring); }
Regards,
PeterOctober 18, 2013 at 4:03 pm #177445Peter, same problem. Just so you know I pasted below what you told me and included in the copy a little bit more code so you can see the placement and make sure it’s accurate.
$fstring = $font_list[‘folder’].’/’.$font_name;
if(!empty($_SERVER[‘HTTPS’]))
{
$fstring = str_replace(‘http://’, ‘https://’, $fstring);
}$output .=”
@font-face {
font-family: ‘{$font_name}’; font-weight: normal; font-style: normal;
src: url(‘{$fstring}.eot{$append}’);
src: url(‘{$fstring}.eot{$qmark}#iefix’) format(’embedded-opentype’),
url(‘{$fstring}.woff{$append}’) format(‘woff’),
url(‘{$fstring}.ttf{$append}’) format(‘truetype’),
url(‘{$fstring}.svg{$append}#{$font_name}’) format(‘svg’);
}—
The errors I get are this FYI:The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.woff?v=2.
(index):40
The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.ttf?v=2.
(index):40
The page at https://livethelife.org/donate/ displayed insecure content from http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.svg?v=2.
(index):40October 18, 2013 at 4:04 pm #177446And yes.. I did delete the cache on both WordPress and browser.
October 18, 2013 at 4:14 pm #177452and this is what I get with firefox
Blocked loading mixed active content “http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.woff?v=2”
Blocked loading mixed active content “http://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.ttf?v=2”—
we have got to fix this somehow.
can you reproduce it on your end? with mine? with your own environment?October 18, 2013 at 7:15 pm #177541Hey!
Mmm… maybe the ssl detection with if(!empty($_SERVER[‘HTTPS’])) fails. Please try to remove the if statement and replace
$fstring = $font_list['folder'].'/'.$font_name;
with
$fstring = $font_list['folder'].'/'.$font_name; $fstring = str_replace('http://', 'https://', $fstring);
Best regards,
PeterOctober 18, 2013 at 9:08 pm #177573nope, same error (after refreshing all cache). Tell me is there a way that we can just put the full URL to those files in the places that it’s calling in the code? There’s got to be a way to get around this. You do see the errors I’m getting though right?
October 19, 2013 at 8:28 am #177778Hi!
I noticed that Kriesi uses another function to include the character map if the new icon font uploader is used. Please revert the change and in /wp-content/themes/enfold/config-templatebuilder/avia-template-builder/php/template-builder.class.php replace
$this->paths['pluginUrl'] = apply_filters('avia_builder_plugins_url', plugins_url().'/'.$this->paths['pluginDir']);
with
$this->paths['pluginUrl'] = apply_filters('avia_builder_plugins_url', plugins_url().'/'.$this->paths['pluginDir']); $this->paths['pluginUrl'] = !empty($_SERVER['HTTPS']) ? str_replace('http://', 'https://', $this->paths['pluginUrl']) : $this->paths['pluginUrl'];
Regards,
PeterOctober 21, 2013 at 5:27 pm #178522I reverted changes on the other file and applied the new changes above to the other file. Refreshed cache, same problem. Can we get Kreisi to jump in and fix this? We really need this working … yesterday. Or do you have any other ideas or advice on how we can resolve this asap?
October 21, 2013 at 5:34 pm #178527Hi!
Please create us an admin account and we’ll look into it. I also tagged this thread for Kriesi in case he wants to look into it.
Cheers!
PeterOctober 21, 2013 at 5:46 pm #178538This reply has been marked as private.October 21, 2013 at 5:53 pm #178546Hey!
Yes, because we can’t modify the theme files without ftp :)
Regards,
PeterOctober 21, 2013 at 6:02 pm #178554This reply has been marked as private.October 21, 2013 at 6:07 pm #178560This reply has been marked as private.October 21, 2013 at 8:03 pm #178619Hey!
I think it’s a server configuration issue. Something forces the http:// protocol and does not allow https. You can test it on your own. Open up /wp-content/themes/enfold/config-templatebuilder/avia-template-builder/php/font-manager.class.php and you’ll notice a new line I added to the file:
$font_list['folder'] = str_replace('http://', 'https://', $font_list['folder']);
It should replace http with https and works on my test server but not on your server. I first thought that I changed the wrong line but in fact your server does not allow https and always replaces https with http again. If you change the line to i.e.:
$font_list['folder'] = str_replace('http://', 'yes://', $font_list['folder']);
the replacement suddenly works and the file paths change to
url('yes://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.woff?v=2') format('woff'), url('yes://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.ttf?v=2') format('truetype'), url('yes://www.livethelife.org/wp-content/themes/enfold/config-templatebuilder/avia-template-builder/assets/fonts/entypo-fontello.svg?v=2#entypo-fontello')
– of course “yes” is not a valid protocol and it just demonstrates the issue with the https string. So it’s not related to the theme code but something on your server (maybe a plugin, maybe the configuration) does not allow the https protocol and will always change it back to http://
Cheers!
PeterOctober 21, 2013 at 9:15 pm #178642This reply has been marked as private.October 21, 2013 at 10:11 pm #178661Hey!
I tagged the thread for Kriesi – hopefully he came across the issue in the past and can provide some useful tips. I don’t know why the https protocol doesn’t work for you. It won’t even accept the protocol relative urls ( http://blog.httpwatch.com/2010/02/10/using-protocol-relative-urls-to-switch-between-http-and-https/ ) and I’ve no idea why.
Cheers!
PeterOctober 23, 2013 at 11:15 pm #179988Hey!
Unfortunately I can’t provide any insight here, never came across something similar :(
Meanwhile did you have any luck getting it to work?Best regards,
KriesiOctober 24, 2013 at 4:22 pm #180285This reply has been marked as private.October 24, 2013 at 4:28 pm #180289This reply has been marked as private.October 25, 2013 at 9:29 am #180552Hi!
We understand the problem but we don’t have a solution because your server replaces the https:// protocol with http:// and does not take care of the theme output. I recommend to try install the theme on another server (and a different hoster without additional plugins, etc.) and check if the https protocol starts to work afterwards. Right now we have no idea why it doesn’t work for you…
Best regards,
Peter -
AuthorPosts
- The topic ‘SSL Pages do not work with Android devices’ is closed to new replies.