javacsript change div text code example Example: how to change text of div in javascript document.getElementById("content").innerHTML = "whatever";