how to change attribute with javascript code example
Example: javascript update attribute
var element = document.getElementById("elemId");
element.setAttribute("attributeName", "value");
var element = document.getElementById("elemId");
element.setAttribute("attributeName", "value");