Welcome Guest, Not a member yet? Register   Sign In
How to validate array value with form validation
#1

[eluser]Lima[/eluser]
sometime I need pass array from form

Code:
<form name="myform" action="" method="post">
<input type="text" name="group[1]" value="" />
<input type="text" name="group[2]" value="" />
<input type="text" name="group[3]" value="" />
</form>

I got an array
Code:
$group = $this->input->post('group');
// or
$group = $_POST['group'];

How to validate $group with form validation class

Thanks
#2

[eluser]BrianDHall[/eluser]
Use a custom callback function: http://ellislab.com/codeigniter/user-gui...#callbacks




Theme © iAndrew 2016 - Forum software by © MyBB