I’m adding markers to a map, and I want to do things when they are clicked
upon, so I’m doing this:
var marker = new OpenLayers.Marker(lonLat,icon);
sitelayer.addMarker(marker);
marker.events.register("mousedown", marker, markerclicked);
But I really want to be able to pass another variable to the callback aswell
that identifies the particular marker, is there any way I can achieve something
like:
marker.events.register("mousedown", marker, markerclicked, myid);
...
function markerclicked(evt, myid) {
}
Or get the same result (identify a specific marker from the callback).
- Thanks, Robert Collier
--
Robert Collier
Network Architect
AlwaysON Group
_______________________________________________
Users mailing list
[email protected]
http://openlayers.org/mailman/listinfo/users