How can I delete all rows of an HTML table except the
this is a simple code I just wrote to solve this, without removing the header row (first one). Hope it works for you!!.\'s using Javascript, and without looping through all the rows in the table? I have a very huge
var Tbl = document.getElementById('tblId');
while(Tbl.childNodes.length>2){Tbl.removeChild(Tbl.lastChild);}