Posted By

noah on 06/06/07


Tagged

DOM eventhandlers ppk interaction


Versions (?)

Who likes this?

4 people have marked this snippet as a favorite

joseluis
vali29
michaJlS
guo3823538


Get the event object and the element that triggered the event


 / Published in: JavaScript
 

See "PPK On JavaScript," p. 323.

  1. foo.onmouseover = function (e) {
  2. var event = e || window.event;
  3. var target = event.target || event.srcElement;
  4. }

Report this snippet  

You need to login to post a comment.