different markers on google maps v3

Posted by user1447313 on Stack Overflow See other posts from Stack Overflow or by user1447313
Published on 2012-06-16T21:11:21Z Indexed on 2012/06/16 21:16 UTC
Read the original article Hit count: 237

i need help again :( How i can add different markers to google map v3. here is example for may marker var latlng = new google.maps.LatLng(lat,lng); var image = "../img/hotel_icon.png"; var locationDescription = this.locationDescription; var marker = new google.maps.Marker({ map: map, position: latlng, title:'pk:'+name, icon: image });

  bounds.extend(latlng);
  setMarkes(map, marker, name, locationDescription);



});//close each
map.fitBounds(bounds);
});//close getjson

}//close initialize
function setMarkes(map, marker, name, locationDescription){
  google.maps.event.addListener(marker, 'mouseover', function() {
      infowindow.close();
      infowindow.setContent('<h3>'+name+'</h3><em>'+locationDescription+'</em>');
      infowindow.open(map, marker);
  });

}

is any help

© Stack Overflow or respective owner

Related posts about JSON

Related posts about google-maps