javascript - Markers are not showing up? -
the following code have map marker based off of the official api , reason when click on marker info window wont open. ideas? doing wrong?
var marker = new google.maps.marker({ position: latlng, map: map, title: "you here! (at least within " + position.coords.accuracy + " meter radius)" }); var contentstring = 'test'; var infowindow = new google.maps.infowindow({ content: contentstring }); google.maps.event.addlistener(marker, 'click', function() { infowindow.open(map, marker); });
Comments
Post a Comment