javascript set span text code example
Example 1: set span text
$("#spanID").text('your text');
Example 2: javascript span style
//an example of an "out of context" way to change color of a text:
<span style="color: green"></span>
Example 3: js add a tag inside span
var span = document.getElementById("span");
var a = document.createElement('a');
a.href = "http://domain.com";
span.appendChild(a);