How to reset all checkboxes using jQuery or pure JS?

streetparade picture streetparade · Feb 17, 2010 · Viewed 179k times · Source

How can I reset all checkboxes in a document using jQuery or pure JS?

Answer

Tatu Ulmanen picture Tatu Ulmanen · Feb 17, 2010

If you mean how to remove the 'checked' state from all checkboxes:

$('input:checkbox').removeAttr('checked');