Answers for "jquery add class to button"

7

add class jquery

$("#my_id").attr("class", "my_new_class_name");
Posted by: Guest on April-13-2020
0

how to add class on the base of has class in jquery

$( "ul li" ).addClass(function( index ) {
  return "item-" + index;
});
Posted by: Guest on October-09-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language