How to remove element using javascript

Posted by Manideepgoud under JavaScript category on | Points: 40 | Views : 66
We use removeChild() to remove element
<div id="div1">
<p id="p1">TechFunda.</p>
<p id="p2">DotNetFunda</p>
var a = document.getElementById("div1");
var b = document.getElementById("p1");

It removes the id value which we have given "p1".

Comments or Responses

Login to post response