Welcome Guest, Not a member yet? Register   Sign In
Validation errors
#4

(10-19-2016, 05:28 AM)dave friend Wrote: form_validation->set_rules takes three arguments - field name, field label, rules.  Documentation here

Looks like you are only providing two arguments.

Try this

PHP Code:
$this->form_validation->set_rules('field_name''''some_rule|another_rule'); 

There's an actual problem hidden here ... The OP did use it incorrectly, but the third parameter should be forcefully required with this usage.

Such is the general issue with having to maintain multiple options and features in one place - allowing set_rules($array_of_stuff) prevents us from making the other parameters non-optional, and obviously nobody thought of actual logical checks for that.
Reply


Messages In This Thread
Validation errors - by RBX - 10-18-2016, 12:35 PM
RE: Validation errors - by dave friend - 10-19-2016, 05:28 AM
RE: Validation errors - by Narf - 10-19-2016, 05:49 AM
RE: Validation errors - by Narf - 10-20-2016, 03:41 AM



Theme © iAndrew 2016 - Forum software by © MyBB