Topic: Validate_fields class not working with checkboxes, radios and select menus. (Read 885 times)
Google dot what?
Posts: 2
16 credits Members referred : 0
« on: Sep 14, 2006, 05:24:22 PM »
I have been playing around with the validate_fields class and have been trouble with getting checkboxes, radio buttons and select boxes to validate.
Have managed to validate textboxes and textareas ok though so thats a start. Any ideas or examples?
Thanks,
Dave
Google dot what?
Posts: 2
16 credits Members referred : 0
« Reply #1 on: Sep 15, 2006, 12:11:32 PM »
Ok,
Have sorted out SELECT boxes out. They're just the same as text funnily enough so apologies for that lame one.
Still can't get the checkboxes to work.The error message i get is: The value in field "Visible?" is not valid.
This is my code: $example->add_check_box("Visible?", $_POST['inpVisible'], "checkbox", "y"); and also have tried: $example->add_check_box("Visible?", $_POST['inpVisible'], "checkbox"); and get the same error.
Any pointers?
Thanks
Moderator Community Supporter?
Jedai Sword Master
Gender:
Posts: 6280
38506 credits Members referred : 374
Have sorted out SELECT boxes out. They're just the same as text funnily enough so apologies for that lame one.
Still can't get the checkboxes to work.The error message i get is: The value in field "Visible?" is not valid.
This is my code: $example->add_check_box("Visible?", $_POST['inpVisible'], "checkbox", "y"); and also have tried: $example->add_check_box("Visible?", $_POST['inpVisible'], "checkbox"); and get the same error.
Any pointers?
Thanks
that's the wrong use check the usage in the example: validation_demo.php