I\'m currently using the following code the place multiple markers on a Google Map using their API.
The problem I\'m having is with multiple infowindows not working
function addMarker(Latlng){
marker = new google.maps.Marker({
position: Latlng,
icon:"myicon.jpg",
map: map,
animation: google.maps.Animation.DROP,
title:"My tooltip"
});
//add marker
marker.setMap(map);
contentString = "Hello World
";
marker.infowindow = new google.maps.InfoWindow({
content: contentString
});
//add click event
google.maps.event.addListener(marker, 'click', function(){
this.infowindow.open(map,this);
});
}
addMarker(some_lat_lang_value);