How can I apply toggleClass() to an input="checkbox" when it has been checked? I'm trying to add the class "calcButtonOn" when checked:
jQuery(function() {
var total = 0;
jQuery("input").click(function() {
total = 0;
jQuery("input:checked").not('input[value="reset"]').each(function() {
total += parseFloat(jQuery(this).val());
});
jQuery("#Totalcost").html("Save up to " + total + "%");
});
});