Welcome Guest, Not a member yet? Register   Sign In
Callback Validation with using two arrays for field names
#1

[eluser]it.peds[/eluser]
In the view, I have several pairs of input fields like below
Code:
<input type="text" name="address[]" value="" />
<input type="text" name="type[]" value="" />

In the controller, I want to set up a callback validation like
Code:
$this->form_validation->set_rules('type[]', 'Address Type', 'callback_requireIfAssoicatedAddressIsFilled[address[]]');

Please advise on how I can code the callback validation, so type[0] is checked with only address[0] not the whole array when looping through the form_validation.excute()


Messages In This Thread
Callback Validation with using two arrays for field names - by El Forum - 02-21-2012, 01:04 PM



Theme © iAndrew 2016 - Forum software by © MyBB