On Dec 8, 8:57 am, Ashwani <[email protected]> wrote:
> Hi Larry, Esa
>
> Thanks for your replies.
>
> After some debugging I was able to resolve the issue. While pushing
> the result object in array now I'm also pushing the
> result.html.cloneNode in the array and while creating marker I pass
> the html from array.
>
> The createmarker is actually a non-google function (in the example
> shared by Larry) which in turns calls GMarker to create marker, hence
> it is the similar thing as new google.maps.Marker(markerLatLng);

The createMarker function retains function closure on its variables,
which is one method of associating the infoWindow content with the
marker.  You can see Mike Williams' explanation in his tutorial:
Javascript Concepts: Function Closure
http://econym.org.uk/gmap/closure.htm

  -- Larry

>
> Changing to marker.bindInfoWindowHtml(result.html.innerHTML) also
> didn't worked.
>
> Regards,
> Ashwani
>
> On Dec 7, 2:21 pm, Esa <[email protected]> wrote:
>
>
>
> > On Dec 7, 8:20 pm, Ashwani <[email protected]> wrote:
>
> > > marker.bindInfoWindow(result.html.cloneNode(true));
>
> > IE6 and IE7 have bugs that make using cloneNode() hazardous.
>
> > You could try instead:
>
> >   marker.bindInfoWindowHtml(result.html.innerHTML);- Hide quoted text -
>
> - Show quoted text -

--

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.


Reply via email to