how to change width of an html element code example Example: javascript set element width document.getElementById("myElID").style.width = "100px";