December 2013
Intermediate to advanced
384 pages
9h 54m
English
$("span").removeClass("oldClass");
You remove classes using the .removeClass([className]) method. For example, to remove the active class from the <span> elements, you call the following:
$("span").removeClass("active");
You can also use remove with no className, which removes all classes from the elements. For example, the following statement removes all classes from <p> elements:
$("p").removeClass();
Read now
Unlock full access