Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

add class javascript

var someElement= document.getElementById("myElement");
    someElement.className += " newclass";//add "newclass" to element (space in front is important)
 
PREVIOUS NEXT
Tagged: #add #class #javascript
ADD COMMENT
Topic
Name
7+9 =