开发者

Google maps kml layer

my code is:

var ctaLayer = new google.maps.KmlLayer(
    'http://.../per1.kml',
     {suppressInfoWindow开发者_运维百科s: true});
ctaLayer.setMap(map);


 var info_percurso = new google.maps.InfoWindow({
  content: 'hi'
 });

  google.maps.event.addListener(ctaLayer, 'click', function() {

  info_percurso.open(map,ctaLayer);

  alert("dd");
}); 

this is possible? this code doesn't work...but the operation is possible?

I need to create my own infoWindow for database queries


make sure the kml is being served. You may need to add the kml MIME type to the server.

application/vnd.google-earth.kml+xml
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜