문제

Senario:

I'm building a website for a man who is driving his tractor across the U.S.A. for the Wounded Warrior charity. He would like to have his route mapped out on the website. And, he would like the blog/event posts as markers on the map as well.

Partial Solutions:

With Google Maps Engine I can create the route easily and embed it on the site. sample

With Google Maps JavaScript API v3 I can easily create markers of the blog posts on a map.

Preferred Solution

BUT, preferably I would to integrate the maps into a single map. So basically I would pull in the Maps Engine map and then add the geolocated blog post via a layer using the API v.3

Is this possible? Can the api communicate with a Maps Engine map? Would I need a Pro account? Or is there a better/easier way to have both a map with a custom route and custom markers?


Ok. Maybe I should have googled some more. Here is what I was looking for. google.maps.visualization.MapsEngineLayer


Even easier… Create a map with with Google Map Engine LITE. Click the folder and select "export to KML". Select the layer you want and use the network link to keep the map up-to-date. Then use google.maps.KmlLayer to draw it on your map!

도움이 되었습니까?

해결책

Yep, check out the Maps Engine Layer and Dynamic Maps Engine Layer. Then add any other layers or visualisations as you would in the v3 API.

https://developers.google.com/maps/documentation/javascript/mapsenginelayers

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top