|NodeCloneNode Method (Boolean)|
The cloneNode() method of the Node interface returns a duplicate of the node on which this method was called. Its parameter controls if the subtree contained in a node is also cloned or not.
Cloning a node copies all of its attributes and their values, including intrinsic (inline) listeners. It does not copy event listeners added using addEventListener() or those assigned to element properties (e.g., node.onclick = someFunction). Additionally, for a <canvas> element, the painted image is not copied.
public Node CloneNode( bool deep )
Public Function CloneNode ( deep As Boolean ) As Node
public: Node^ CloneNode( bool deep )
member CloneNode : deep : bool -> Node
If true, then the node and its whole subtree, including text that may be in child Text nodes, is also copied.
If false, only the node will be cloned. The subtree, including any text that the node contains, is not cloned.