Uso de la API de Google Maps v3
Nota: Los archivos KML deben ser de acceso público, en un servidor web. La API de Google Maps tiene un soporte KML limitado (líneas simples, puntos, polígonos están bien)
cambio: var ctaLayer = new google.maps.KmlLayer(' http://gmaps-samples.googlecode.com/svn/trunk/ggeoxml/cta.kml '); ctaLayer.setMap(map); a su kml
y el var chicago = new google.maps.LatLng( 41.875696,-87.624207 ); a su punto central.
http://code.google.com/apis/maps/documentation/javascript/examples/layer-kml.html
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
<title>Google Maps JavaScript API v3 Example: KmlLayer KML</title>
<link href="http://code.google.com/apis/maps/documentation/javascript/examples/default.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
<script type="text/javascript">
function initialize() {
var chicago = new google.maps.LatLng(41.875696,-87.624207);
var myOptions = {
zoom: 11,
center: chicago,
mapTypeId: google.maps.MapTypeId.ROADMAP
}
var map = new google.maps.Map(document.getElementById("map_canvas"), myOptions);
var ctaLayer = new google.maps.KmlLayer('http://gmaps-samples.googlecode.com/svn/trunk/ggeoxml/cta.kml');
ctaLayer.setMap(map);
}
</script>
</head>
<body onload="initialize()">
<div id="map_canvas"></div>
</body>
</html>