Reputation: 2654
I am loading kml files on Google maps. 99% of the time it works but there have been instance when the kml file does not fully load. Currently i am caching the kml files every night in memcache so it does not need to send request to Google every time. I have attached pictures where you can see the kml file is half loaded. I cannot see any errors in Apache, browser or application logs. Can anyone help?
https://i.sstatic.net/vT0zQ.jpg
https://i.sstatic.net/DoJPc.jpg
Upvotes: 0
Views: 370
Reputation: 21091
These lines are rendered server side by GMaps, as image tiles.
Unfortunatly sometimes Gmaps - for some unknown reason fails to draw some tiles. And once its failed, the failed tile is cached. You can sometimes get round it by refreshing the browser.
I dont think there is a known solution, other than forcing GMaps to try to redraw the tiles - easiest way to do that is to change the url of the kml file - so gmaps renders it from scratch.
Could just add a fake paramater in JS, which is then ignored by your server, but gmaps sees it as a new url.
Upvotes: 1