Oh okay thanks. I resolved it by echoing the php contents to a javascript array then putting that into a for loop that runs it through one at a time. I got the code sample from http://econym.org.uk/gmap/example_map9.htm if anyone else is having this problem.
On Oct 6, 4:37 pm, Rossko <[email protected]> wrote: > > address = "Ithaca, New York, United States"; > > if (address2 != address) { > > geocoder.getLocations(address, addToMap); > > } > > address2 = address; > > address = "Fountain Valley, California, US"; > > if (address2 != address) { > > geocoder.getLocations(address, addToMap); > > } > > Can you see anything wrong here? The second geocoder.getLocations() > destroys the first one. This stuff is asynchronous - you know that > because you've looked at code that implements delays etc. > http://econym.org.uk/gmap/async.htm > That means it takes time to get the results from the first call, but > the browser doesn't stop and wait. Before the results get back, your > code ploughs ahead and re-sets all the geocoder settinngs and fires > off the next shot. > You must either give them seperate geocoder objects to work on, or you > must wait until one is complete before firing the next one. > > The latter is the best choice anyway, as Google implement a speed > limit to stop people hogging resources with quickfire requests. > http://econym.org.uk/gmap/geomulti.htm > > The very best advice with multiple geocoding is ... just don't do it, > every time someone looks at your page. Store the locations of your > known addresses ahead of time. > > cheers, Ross K --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
