I want to transfer the corresponding marker identifier by clicking the marker on the google map. I am using the marker.getId () function to retrieve the marker identifier. But the token id does not match the url. How can i do this? Any help?
function AddressMap(lat,lang,markerid) { var latLng = new google.maps.LatLng(lat,lang); var marker = new google.maps.Marker({ 'map': map, position: latLng, 'latitude' :lat, 'longitude' :lang, icon: image, shadow: shadow, id: markerid }); markers.push(marker); google.maps.event.addListener(marker, 'click', function() { window.location = "www.cickstart.com/" + marker.getId(); }); }
srinu source share