On Jun 29, 3:01 pm, Aresh Amoli <[email protected]> wrote: > Thanks for your help. I went through the website and I checked my code to > see where I was going wrong but all I could see was my onload was not called > onLoad and I moved the map.Overlay further down still no difference. Is it > my coding which is wrong or is sections of the code in the wrong place?
You're not using a function to create your markers. Every iteration of your loop creates a new instance of "marker", and at the end of the loop, only the last instance is accessible. Thus every listener opens the infoWindow of the marker called "marker". It's Pitfall Number Three in Mike's tutorial. Using a function like Mike's "createMarker" localises each marker and allows it to be accessed separately. Andrew --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
