The code in example 1 works. I would like to understand the marker.setIcon(); function more (new to JavaScript also). My question is. In the documentation for Google maps you see s
Solution 1:
You're giving a V2 answer for a V3 question.
There is no GIcon in V3.
var image = new google.maps.MarkerImage("newIcon.png");
Can be used inside your marker as the icon.
var marker = new google.maps.Marker({
position: new google.maps.LatLng(lat,lng),
icon:image
});
Share
Post a Comment
for "Changing Google Maps V3 Maker Icon The Correct Way?"
Post a Comment for "Changing Google Maps V3 Maker Icon The Correct Way?"