When using the Google Maps API, I am having troubles adding the KML Layer.
Using the following javascript, the map renders fine.
function initialize() {
var mapOptions = {
zoom: 8,
center: new google.maps.LatLng(49.754,-115.834),
mapTypeId: google.maps.MapTypeId.ROADMAP
};
var map = new google.maps.Map(document.getElementById('map_canvas'),
mapOptions);
//var ctaLayer = new google.maps.KmlLayer('http://forestcrowne.ca/earth/dave.kml');
//ctaLayer.setMap(map);
}
google.maps.event.addDomListener(window, 'load', initialize);
When I uncomment the ctaLayer, the map disappears (yesterday it would render the kml file, but the map still disappeared). What is happening?
Take a look:
http://forestcrowne.ca/?page_id=1647 – with ctaLayer commented
http://forestcrowne.ca/?page_id=1668 – with ctaLayer uncommented
The KmlLayer displays fine when not on your page. Try not using the “experimental/nightly build” version of the API, change:
To call out a specific version (or v=3)
So, thanks to all the help – I got it. I changed the background-color to transparent on the “Images in Posts”. Atahualpa has some fancy css to create radiused borders on images – one of the properties specified in background-color. So.. it was the css