Answers for "append li to ul javascript"

0

append li to ul javascript

function function1() {
  var ul = document.getElementById("list");
  var li = document.createElement("li");
  li.appendChild(document.createTextNode("Four"));
  ul.appendChild(li);
}
Posted by: Guest on September-30-2020
1

how to appendChild in the begin of the div javascript

var element = document.getElementById("div1");
element.insertBefore(para, element.firstChild);
Posted by: Guest on June-24-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language