Google Map Not Displaying

Part of my web app (Web 1.0) is to display a map of an address. In my development machine, it’s working fine. Built and installed the app on the server. Tested the app via localhost:8080 on the server’s browser, it’s working fine. Access the app remotely through “myapp.com”, google map is not displaying on any browser. No error, just not showing.

What have I done wrong?

It seems that it has no problem when executed from the local machine but does not behave as expected when called remotely.

Btw, I’m using Xojo 2017r3, Windows 10.

any error message in the console of the developer pane on the browser ?

1 Like

Is your connection secure? I don’t do much with Google Maps, but I think it has to be served over SSL.

3 Likes

This is the error:

Mixed content: load all resources via HTTPS to improve the security of your site.
Even though the initial HTML page is loaded over a secure HTTPS connection, some resources like images, stylesheets or scripts are being accessed over an insecure HTTP connection. Usage of insecure resources is restricted to strengthen the security of your entire site.

Thank you for your guidance, Jean, as I am able to solved the issue. Thank you also for your input Anthony. Yes, my website is over SSL but I’m calling the Google API from Xojo using http only. My bad.

1 Like

And just for future readers: it is not only Google. Almost all (serious) services are enforcing HTTPS these days, but not always with any or a clear error message and it is just too easy to overlook the missing ‘s’ in your code. Happen to me a few times, after copying some older stuff …

1 Like

BTW - The reason it works locally is that many of these services allow a special exception for connections to localhost or 127.0.0.1 because they know that many developers test locally.

3 Likes