views:

125

answers:

1

I m making a google maps with some coordinates and directions and when a user clicks a marker and appears a info window there's a link avaliable, when user clicks it, i want to catch click event inside info window, and make zoom to this marker, anyone had to deal with link clicks in google maps api could help me with some links, documentation or hints?

A: 

Use an onclick attribute inside the link that appears in the info window with something like (this might need correcting):

 <a onclick="map.setCenter(yourmap(37.4419, -122.1419), 13);">Info link</a>

API reference

Jonno_FTW
i d like a solution that would not imply to mixup markup with javascript, some kind of solution that could involve anything like $('h4.fn').bind('click',function(){//blah blah})
markcial
@markcial: so you can use jQuery?
Crescent Fresh
yup, is wide avaliable in the site im working it
markcial