I have a series of a series of rows and checkboxes to filter them:
&l
$("table tr").hide(); $("input[id^='type-']").each(function() { element = $(this); $("table tr").each(function() { if($(this).hasClass(element.id.replace('type-','')) { if(element.is(":checked") { element.show(); } } }); }).change();