When I click my webpage I don't get any results. What is wrong with my code?
webpage: http://map.niraengineers.com GEvent.addListener(map, 'click', getDistance); function getDistance () { var point1 = new GLatLng(); map.addOverlay(point1); polylineOverlay = new GPolyline(point1,'#FF9601',3,1); map.addOverlay(polylineOverlay); var point2 = new GLatLng(); var distance = directions.getDistance(point1 , point2).meters; alert(distance.toString()); } -- 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.
