samedi 3 février 2018

checkbox is undefined in $_POST unless it is checked

I have many checkboxes like this.

<input type="checkbox" name="isGood[]">

For example, i have 6 checkboxes then i checked 3 of them. When i submit it, the "print_r($_POST)" shows only array(isGood => array([0] => "on", [1] => "on", [2] => "on"))

And the other is undefined. Please help me to fix this.




Aucun commentaire:

Enregistrer un commentaire