Kurt Mackey schrieb:
> Is there a “jQuery” way of getting an event’s click target?  I tend to 
> use those elements quite a bit, but getting them is a pain. J

Hi Kurt,

jQuery provides no functionality to retrieve the target. Here's my way 
to do that:


$( ... ).click(function(e) {
     var ev = e || event;
     var target = ev.target || ev.srcElement;
     $(target).css('border', '1px solid red');
});

Maybe that should be abstracted by jQuery...


-- Klaus

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to