change span text javascript code example
Example 1: javacsript update text in span
document.getElementById("myspan").textContent="newtext";
Example 2: change span value javascript
document.getElementById("serverTime").innerHTML = ...;
Example 3: set span text
$("#spanID").text('your text');