event.relatedTarget

The other DOM element involved in the event, if any.

For mouseout, indicates the element being entered; for mouseover, indicates the element being exited.

event.relatedTarget
version added: 1.1.4
Examples:

On mouseout of anchors, alert the element type being entered.

$( "a" ).mouseout(function( event ) {
  alert( event.relatedTarget.nodeName ); // "DIV"
});
doc_jQuery
2016-03-27 13:48:17
Comments
Leave a Comment

Please login to continue.