dimanche 12 janvier 2020

onClick button function for a "selecting all" toggle on checkboxes

How would I go about making a javascript for a button to select and deselect all checkboxes?

Checkbox HTML (they all look the same with a different value):

<input type="checkbox" name="moviebox[]" value="Zombieland" style="width: 15px; height: 15px; margin: 0px;">

My button:

<input type="button" value="Select All/None">



Aucun commentaire:

Enregistrer un commentaire