Answers for "how to delete all li on page in js"

3

remove all options from select jquery

$('#mySelect')
    .empty()
Posted by: Guest on March-18-2020
0

javascript get all script tags on page

var scripts = document.getElementsByTagName("script");
for (var i = 0; i < scripts.length; i++) {
  if (scripts[i].src) {
  	console.log(i, scripts[i].src);
  } else { 
    console.log(i, scripts[i].innerHTML);
  }
}
Posted by: Guest on December-11-2019

Code answers related to "Javascript"

Browse Popular Code Answers by Language