JavaScript checkbox toggle

Demo shows how to toggle or clear a checkbox group. On button click, all checkboxes in HTML table will change their state. Checkbox group can be defined with any container so it’s not necessary to use a table. This is a really simple JavaScript function with checkbox toggle and clear options.