Welcome Guest, Not a member yet? Register   Sign In
Validation callback function inside model
#11

[eluser]gtech[/eluser]
sorry didn't mean to put you down its not easy starting out on a new technology, and I dont know half of CI. I just strongly believe validation belongs in the controller and you call the model in the callback functions, you are doing something the validation code isnt designed to do.. I will take a look at how the callback functionality works for you.

[edit]
where are your loading your validation library?, in the controller or in the model? If I understand the validation code correctly(which is debatable) the callback function works by storing a reference to the code its initialised by in $this->CI. It then parses out "callback_" and stores the function name in $rule... The callback looks like this: $this->CI->$rule(......


Messages In This Thread
Validation callback function inside model - by El Forum - 11-06-2007, 04:13 AM
Validation callback function inside model - by El Forum - 11-06-2007, 04:36 AM
Validation callback function inside model - by El Forum - 11-06-2007, 05:16 AM
Validation callback function inside model - by El Forum - 11-06-2007, 05:26 AM
Validation callback function inside model - by El Forum - 11-06-2007, 05:35 AM
Validation callback function inside model - by El Forum - 11-06-2007, 05:48 AM
Validation callback function inside model - by El Forum - 11-06-2007, 05:55 AM
Validation callback function inside model - by El Forum - 11-06-2007, 06:10 AM
Validation callback function inside model - by El Forum - 11-06-2007, 06:39 AM
Validation callback function inside model - by El Forum - 11-06-2007, 07:03 AM
Validation callback function inside model - by El Forum - 11-06-2007, 07:13 AM
Validation callback function inside model - by El Forum - 11-06-2007, 07:37 AM
Validation callback function inside model - by El Forum - 11-06-2007, 07:39 AM
Validation callback function inside model - by El Forum - 11-06-2007, 07:56 AM



Theme © iAndrew 2016 - Forum software by © MyBB