Change the style class of an element - Node.js HTML

Node.js examples for HTML:Element

Description

Change the style class of an element

Demo Code

function swapClass(obj, newStyle) {
    obj.className = newStyle;/*from  ww w .  j  a  v  a  2  s  .  c o  m*/
}

Related Tutorials