I am trying to use checkboxes to filter page content. I got it to hide content when I check the box, but it does not show all content again when unchecked. Any help would be greatly appreciated. Thank you in advance.
$(document).ready(function() {
$('input').change(function(){
$('input').each(function(){
var checked;
if (checked = $(this).attr('checked'));
var reclessons = $('li[data-rec='+$(this).data('rec')+']');
checked ? reclessons.show('slow'): reclessons.hide('slow');
});
var unchecked=0;
if(unchecked=0){$('li').show('slow');}
});
});
ifstatements have==