CI 2.2 Form Validation not working as expected |
This is CI 2.2.3
I'm using an array for the name of a set of input values 'opt' (ie opt[1] opt[2] ...). Here is a dump of the validation config array passed to form_validation->set_rules(). As you can see the some of the input are required but fields Email and Phone are not. Email is using a CI supplied function (valid_email) while Phone is using a function in our MY_form_validation class. If no input is supplied for the Email and Phone input field no error should be issued, but one is. This looks like a bug to me. TEST - 2015-10-18 10:16:34 --> Array ( [0] => Array ( [field] => opt[1] [label] => Team Manager Name [rules] => trim|required|max_length[50] ) [1] => Array ( [field] => opt[2] [label] => Team Kind [rules] => trim|required|max_length[50] ) [2] => Array ( [field] => opt[4] [label] => Email [rules] => trim|valid_email ) [3] => Array ( [field] => opt[3] [label] => Phone [rules] => trim|phone ) ) |
Messages In This Thread |
CI 2.2 Form Validation not working as expected - by SRGreenwood - 10-18-2015, 07:29 AM
RE: CI 2.2 Form Validation not working as expected - by PaulD - 10-18-2015, 06:56 PM
RE: CI 2.2 Form Validation not working as expected - by Avenirer - 10-18-2015, 11:48 PM
RE: CI 2.2 Form Validation not working as expected - by SRGreenwood - 10-21-2015, 12:37 PM
RE: CI 2.2 Form Validation not working as expected - by Avenirer - 10-27-2015, 01:21 PM
RE: CI 2.2 Form Validation not working as expected - by joseph.dicdican - 10-26-2015, 11:50 PM
RE: CI 2.2 Form Validation not working as expected - by SRGreenwood - 10-27-2015, 03:32 AM
RE: CI 2.2 Form Validation not working as expected - by joseph.dicdican - 10-27-2015, 08:37 AM
|