Javascript Reference
Categories: event

javascript event relatedNode

@March 15, 2008, 1:22 a.m.
relatedNodeFirefox/Netscape/NN 6 IE n/a Chrome/Safari/DOM 2

Read-only

Returns a reference to a node that is affected by the action that triggers some W3C DOM mutation events. This provides a more direct route to a node that is impacted by the event, according to the following table.

 

For other mutation event types, the property returns null; for other event classes, the property returns undefined.

 
Mutation event typeeventObj.relatedNode reference
DOMNodeInsertedParent node of inserted node
DOMNodeRemovedOriginal parent node of removed node
DOMAttrModifiedAttr node
 
Example
 
var newParent = evt.relatedNode;
 
Value

Reference to a node, null, or undefined.

 
Default

None.


Powered by Linode.