The reverse geocoding seems to be working OK, but I can see two other
problems:
In this code
marker = new GMarker(point);
markers.push(marker);
map.addOverlay(new GMarker(point));
The marker that gets stored in markers[] isn't the one that gets
addOverlay()ed. So when you try to open the info window on
markers[row_no-1] it fails because that marker is not added to a map.
In this code
GEvent.addListener(map, 'click', function(overlay, latlng) {
var lat = latlng.lat();
You fail to check whether the click occurred on an overlay or on the
underlying map. If you click on an existing marker, then "overlay" is a
reference to that marker, and "latlng" is void. So latlng.lat() does not
exist and the code crashes.
--
http://econym.org.uk/gmap
The Blackpool Community Church Javascript Team
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Maps-API?hl=en
-~----------~----~----~----~------~----~------~--~---