I have a form (register.php) that has multiple checkboxes:
<input type="checkbox" name="activities[]" value="1"> option 1
<input type="checkbox" name="activities[]" value="2"> option 2
<input type="checkbox" name="activities[]" value="3"> option 3
I have this form going to register2.php which checks the variables of this form and if some fields are not filled in, then it:
if(empty($error)) {
// write to database
}
else {
include("register.php");
}
Which it then pulls up the register.php file again with all the variables EXCEPT the checked checkboxes.
Can anyone tell me how to get those checkboxes be be checked if they where before?
Thanks alot