Skip to content

Instantly share code, notes, and snippets.

@progerio
Created April 2, 2020 22:54
Show Gist options
  • Save progerio/041ecbc10b65a89267056941070c452c to your computer and use it in GitHub Desktop.
Save progerio/041ecbc10b65a89267056941070c452c to your computer and use it in GitHub Desktop.
Jquery - check all input checkbox
function checkAll(){
$("#checkTodos").click(function(){
$('input:checkbox').not(this).prop('checked', this.checked);
});
}
document.ready(function(){
checkAll();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment