document get element by tag
snippet in javascript

document get element by tag

user1720

var list = document.getElementsByTagName("UL")[0];
list.getElementsByTagName("LI")[0].innerHTML = "Milk";

get element by tag name

user7925


var list = document.getElementsByTagName("UL")[0];

list.getElementsByTagName("LI")[0].innerHTML = "Milk";