'cloneNode()' Example : cloneNode « Javascript Methods « JavaScript Reference
- JavaScript Reference
- Javascript Methods
- cloneNode
'cloneNode()' Example
<html>
<body>
<script language="JavaScript">
function function1(){
var myNode = myButton.cloneNode(true);
alert(myNode.innerHTML);
}
</script>
<button id="myButton" onclick="function1();">Clone node</button>
</body>
</html>
Related examples in the same category