Amitesh Verma

Amitesh Verma

  • NA
  • 746
  • 86.7k

KML layers in google map

Jul 25 2013 5:29 AM
i have a KML layer file...saved in my harddisk...select it and use it...i want code to get the layerrs from harddisk and display it....i got some codes...but i wasnt working...posting it...
 function a2()
{
 var chicago = new google.maps.LatLng(41.875696, -87.624207);
 var mapOptions =
 {
 zoom: 11,
center: chicago,
 mapTypeId: google.maps.MapTypeId.ROADMAP
 }
 var map = new google.maps.Map(document.getElementById('map-canvas'),
 mapOptions);
 var ctaLayer = new google.maps.KmlLayer(
{ url: 'C:/gmap.kml' }
);
 ctaLayer.setMap(map); google.maps.event.addDomListener(window, 'load', a2);
 }

Answers (2)