selectAllChildren Redirect 1

« DOM Reference

Summary

Adds all the children of the specified node to the selection. Previous selection is lost.

Syntax

sel.selectAllChildren(parentNode)

Parameters

parentNode
All children of parentNode will be selected. parentNode itself is not part of the selection.

Examples

footer = document.getElementById("footer");
window.getSelection().selectAllChildren(footer);
/* Everything inside the footer is now selected */
 

Document Tags and Contributors

Last updated by: Sheppy,