jquery add class to button code example
Example 1: add class jquery
$("#my_id").attr("class", "my_new_class_name");
Example 2: how to add class on the base of has class in jquery
$( "ul li" ).addClass(function( index ) {
return "item-" + index;
});