I have an issue that I have been unable to troubleshoot with my 
infowindows. You can view the page where the problem occurs at 
http://www.queenofnewyork.com/
Click any marker on the map, and as soon as it appears, a javascript error 
is registered, which prevents the infowindow from closing.

My map code is contained in a javascript class 
(http://www.queenofnewyork.com/wp-content/themes/queenofnewyork/js/map.js)
Inside, I have a method called showMarkers which takes as argument an 
array, as follows: 

    this.showMarkers = function (places) {
        for ( var i = 0 ; i < places.length ; i++) {
            var marker = new google.maps.Marker({
              position: places[i]['LatLng'], 
              map: this.map,
              title: places[i]['title'],
              icon: icon,
              html: places[i]['html']
            })
            google.maps.event.addListener(marker, 'click', function () { 
                infoWindow.setContent(this.html) ;
                infoWindow.open(map, this); 
            }); 
            markersArray.push(marker);                          
        }

My markers and infowindow appear as expected, but I'm stuck with this 
javascript error which prevents the infowindow from closing.
Any idea what I am doing wrong?
Thanks in advance for your help.

Lothaire

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-maps-js-api-v3/-/c8mzCCTk0uYJ.
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-js-api-v3?hl=en.

Reply via email to