> How can I fix this?
>
> Should I call initialize within loadXML?
The usual approach would be to put just the code that processes the
XML data inside the callback function, and leave the map initializing
outside.
In your case, take the code beginning
var bounds = new GLatLngBounds();
for (var i = 0; i < latD.length; i++) {
and put it after
lonD = xml.documentElement.getElementsByTagName...
The next problem you will run into is that your map object is local to
your intialize() function, so map.addOverlay will fail. Declare it in
global scope.
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
-~----------~----~----~----~------~----~------~--~---