Welcome Guest, Not a member yet? Register   Sign In
Form Validation RUNS first time page is loaded
#2

[eluser]acoda[/eluser]
I might be mistaken but I beleve all you have to do is switch your if statement to a negative check in the controller:

Code:
if ($this->form_validation->run() == FALSE)
{
    $data['title'] = $this->sample_model->_get_title();
    $this->load->view('title_view', $data);
}
else
{
    //YES, true - if success,
    //code to update database
}

Not checked it but I'm pretty sure. Hope this helps Smile


Messages In This Thread
Form Validation RUNS first time page is loaded - by El Forum - 10-15-2009, 06:49 PM
Form Validation RUNS first time page is loaded - by El Forum - 10-15-2009, 07:47 PM
Form Validation RUNS first time page is loaded - by El Forum - 10-16-2009, 01:20 AM
Form Validation RUNS first time page is loaded - by El Forum - 10-22-2009, 12:06 PM



Theme © iAndrew 2016 - Forum software by © MyBB