Thanks William! That worked. Do you also have a pointer for my second question, Regarding my second question: What's the html to reference a marker (and trigger the balloon) from outside the map, on the same page? ie: <A HREF="???">Mary</A>
Many thanks John On Apr 24, 1:25 am, William <[email protected]> wrote: > On Apr 24, 9:20 am, JohnH <[email protected]> wrote: > > > I'm making an API V3 map which contains multiple markers, > > and am having no luck finding V3 documentation on how to close the old > > balloon-tip when a new marker is clicked and new balloon appears (in > > other words, so that only one balloon is ever displayed). > > you will need to create only one InfoWindow, and set the content > before opening it, something like this: > > var infowindow = new google.maps.InfoWindow(); > > google.maps.event.addListener(marker1, 'click', function() { > infowindow.setContent('Hello Mary'); > infowindow.open(map, marker1); > > }); > > google.maps.event.addListener(marker2, 'click', function() { > infowindow.setContent('Hello Fred'); > infowindow.open(map, marker2); > > }); > > -- > You received this message because you are subscribed to the Google Groups > "Google Maps JavaScript API v3" 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 > athttp://groups.google.com/group/google-maps-js-api-v3?hl=en. -- You received this message because you are subscribed to the Google Groups "Google Maps JavaScript API v3" 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-js-api-v3?hl=en.
