I have a FancyBox in the home page which contains a registration form.
Validation is working fine.
Currently, I have to manually click on the FancyBox to see the error messages on that form.
Here's the code which reloads the page. But I want it to show the FancyBox as soon as the page loads. It is just a simple validation check.
if ($this->form_validation->run() == FALSE)
{
$this->load->view('valform');
}
else
{
$this->load->view('formsubmit');
}
So what I want is to show that FancyBox with validation errors.
Validation is working, as it is shown in the FancyBox; when the page reloads I have to manually click on that FancyBox to see the validation errors. Is there a way I can store it in a session and use that instead? If yes, how? Or how can I use ajax for this, and get validation errors to show on the FancyBox?