Surendra singh

Surendra singh

  • 1.9k
  • 136
  • 67.2k

Google map's Info-Window resize after ajax call

Feb 27 2015 8:37 AM
I am using Google Map's Info-window to display some information. after every one minutes, page refresh using ajax call, and rebinds the data on map. And we re-open the Info-windows with refreshed data. but after ajax call, Info-windows are not opening in original size, they resized after ajax refresh and open in small size. I tried to resize again to original size using "gm-style-iw" css class. but it some time shows in original size and some time open in small size.

I'll be highly thankful to you guys for the suggestions.
                                function GetInfoWindowPoints()
                for(var i=0;i<=infoWindowPoints.length-1;i++)
                    var infowindow = new google.maps.InfoWindow({
                        content: infoWindowPoints[i].popUpData,
                        maxWidth: 400,
                            disableAutoPan: true
                        //infowindow.setOptions({maxWidth : 300});
                        var latlngInfo=infowindow.getPosition();             
                            // alert(value.latLng+", "+latlngInfo);
                            return  value.latLng !=latlngInfo;
                var myVar = setInterval(function(){   
                }, 10000);

Following image is coming after ajax refresh. It this image info-windows are not opening properly.