javascript - Google Maps API Won't SHOW ICONS -


perfect!

these websites won't populate icons on google maps i've added api make sure does,

http://www.laketonopahliving.com/community

but these website , doesn't have api:

http://www.1001melroseapts.com/community

what need above link map bottom link map?

thanks!

you need array of markers can add map.

ideally marker locations added db can store latitude , longitutde each marker point, latitude , longitude google uses place markers on map.

so if had array of locations following:

var locations = [     {lat: 38.1234324, lng: 78.123234, name: "test 1", id:1},     {lat: 39.1234324, lng: 79.123234, name: "test 2", id:2},     {lat: 40.1234324, lng: 80.123234, name: "test 3", id:3},     {lat: 41.1234324, lng: 81.123234, name: "test 4", id:4} ] 

you loop on array , add markers map this:

$.each(locations, function(idx, location) {     new google.maps.marker({             position : new google.maps.latlng(location.lat, location.lng),             title: location.name,             map: map //map map object instance     }); }); 

Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -