Welcome Guest, Not a member yet? Register   Sign In
Problem inserting multiple fields to database
#2

[eluser]Thorpe Obazee[/eluser]
I'd say you'd have to have 3 validation rule sets and use

Code:
if ($this->form_validation->run('first_input_rule_set') == TRUE)
{
    do stuff
}

if ($this->form_validation->run('second_input_rule_set') == TRUE)
{
    do stuff
}

if ($this->form_validation->run('third_input_rule_set') == TRUE)
{
    do stuff
}

You also need to modify your view to have different fieldnames instead of fieldname[]

One problem is that I don't know if two or more form validation rule sets could run at one request. Haven't tried it though.


Messages In This Thread
Problem inserting multiple fields to database - by El Forum - 05-06-2009, 04:49 PM
Problem inserting multiple fields to database - by El Forum - 05-06-2009, 04:53 PM
Problem inserting multiple fields to database - by El Forum - 05-07-2009, 12:29 AM



Theme © iAndrew 2016 - Forum software by © MyBB