YM4R/GM-Plugin: Events on Markers

I don’t like ('cause I don’t know) Javascript, that’s why I’m trying
to figure out how to implement the whole GoogleMaps-part of my
application using Ruby/Rails.

I’ve a problem registering events on markers:


The event-listener works for map-events if i use ‘@map’ instead of
@my_marker’ on line 15.

The big picture:
I’d like to read latitude and longitude as soon as the user drags the
marker to a location on the map.