Welcome Guest, Not a member yet? Register   Sign In
set_radio and set_checkbox have problems with value of 0
#18

[eluser]CroNiX[/eluser]
Any of the form_helper functions that retrieve a form value need at least one validation rule set up. set_value(), set_select(), set_radio(), set_checkbox(), etc., or they can't get the value.

I don't know why you'd use an empty rule though. I'd at least make a callback function to see if that field was an int 0 or 1, or whatever allowable choices you have. If it goes in the database, it should be validated. What if I edited the form in my browser and sent "3" and that wasn't an allowable or valid choice? Your code would store it.


Messages In This Thread
set_radio and set_checkbox have problems with value of 0 - by El Forum - 11-13-2013, 04:45 PM



Theme © iAndrew 2016 - Forum software by © MyBB