JQuery Validasi kotak centang sebelum dikirim

$(document).ready(function() {
    $('#form1').submit(function() {
        if ($('input:checkbox', this).length == $('input:checked', this).length ) {
            // everything's fine...
        } else {
            alert('Please tick all checkboxes!');
            return false;
        }
    });
});
Bewildered Butterfly