0
votes

I am able to load KML into Google Maps despite what this answer says, but my problem is that there is no data coming in from Google's servers. All I get is a blurry map from the default texture that comes with the Google Earth plugin. Uploading the same html file to a public web server works.

enter image description here

Google is probably sending the window.location and checking if it can visit the URL from their end - if not then it denies any access to map data. This is to prevent people deploying apps locally (e.g. intranets) and not buying a license. I want to be able to develop locally, and this is restricting that ability.

1
Apache, and it's weird because it works occasionally... Not sure what the reason is. - Aram Kocharyan
I don't think Google differentiates when you load from a local server or from the filesystem, since either is still local and unreachable (if this is what they're checking). - Aram Kocharyan
Im not sure about apache, but I am using IIS and you can use something along the lines of 'aramscomputer/path_to_kml_file' to load kml files locally, and it would be the same as 'localhost/path_to_kml_file'. - Matt

1 Answers

2
votes

I had the same problem, what helped me was to open the server's HTTP port on my router (and if you have a firewall you need to open the port there as well).