change multiple css properties js code example
Example 1: set multiple attributes css javascript
document.getElementById("myElement").style.cssText = "display: block; position: absolute";
Example 2: setting multiple css using dom
document.getElementById("myElement").style.cssText = "display: block; position: absolute";