Google maps, SSL and chrome

General Discussion about the commercial Enuuk Auction Platform
Post Reply
bamse
Posts: 220
Joined: Mon Feb 06, 2012 12:05 pm
Contact:

Google maps, SSL and chrome

Post by bamse » Mon Mar 04, 2013 3:20 pm

It seems that chrome does not like the line

Code: Select all

<script src="http://maps.google.com/maps/api/js?sensor=true" type="text/javascript"></script>
in themes/.../header.php if using SSL for the site.

In the console it gives an error message saying something about loading unsecured content (don't remember the exact text). It also seems to not load all javascript as for instance the bid history is not hidden on the offerDetail page. I did not see this error message in firefox.

Changing http to https in above line seems to fix the problem in chrome.

RWAP
Site Admin
Posts: 750
Joined: Fri Jan 08, 2010 2:23 am
Location: Stoke-on-Trent
Contact:

Re: Google maps, SSL and chrome

Post by RWAP » Mon Mar 04, 2013 3:34 pm

You need to change that line to read:

Code: Select all

<script src="<?=$siteOptions['protocol']?>://maps.google.com/maps/api/js?sensor=true" type="text/javascript"></script>
No idea why other javascript is not loading in https mode.

Can you report this to Enuuk please.

bamse
Posts: 220
Joined: Mon Feb 06, 2012 12:05 pm
Contact:

Re: Google maps, SSL and chrome

Post by bamse » Mon Mar 04, 2013 5:09 pm

True, this is a more elegant solution respecting the siteOption settings.

For the record the error message I got in chrome when accessing an offerDetailsStandard page was:

[qutoe]
[blocked] The page at https://www.mydomain.com/offer/details/ ... en_frog-18 ran insecure content from http://maps.google.com/maps/api/js?sensor=true.

Uncaught ReferenceError: google is not defined
[/quote]

And I get the same error message from the youtube links in offerDetailsStandard (and likely other offerDetail pages if I used those). Fix as above seems to work for this case.

But still I am getting error messages when I actually run the video.

In the chrome console it says (many times) "displayed insecure content" from some longish youtube url. And the green SSL lock in the url bar gets a yellow triangle saying: "Your connection to http://www.mydomain.com is encrypted. However this page includes other resources which are not secure...."


Not sure why it affects the loading of javascript (hiding of bid history) or why this is only an issue with chrome and not with firefox.

Still investigating...

bamse
Posts: 220
Joined: Mon Feb 06, 2012 12:05 pm
Contact:

Re: Google maps, SSL and chrome

Post by bamse » Mon Mar 04, 2013 5:22 pm

I guess, based on

http://apiblog.youtube.com/2011/02/http ... mbeds.html

there is nothing I can do about this, right?

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest