set the value of a html element javascript code example
Example 1: javascript set input field value
document.getElementById("myInputID").value = "My Value"; //set value on myInputID
Example 2: set text of dom element
document.getElementById("myBtn").textContent = 'Hello World';