I have a form in a page that pass the output data to another page containing another form.
The problem is that when I try to browse the second page, the validation errors of this page are displayed, because it see the POST array from the form in the page 1 and so it doesn't have the same inputs required to pass the validation error, it display the validation message.
Here is the code in the controller of the second form:
function download_application()
{
//load the libraries
$this->load->library('form_validation');
//form validation
$this->form_validation->set_rules('name', 'name is required', 'required');
$this->form_validation->set_rules('email', 'email is required', 'required|valid_email');
$this->form_validation->set_rules('country', 'country is required', 'required');
$this->form_validation->set_rules('phone', 'phone is required', 'required');
if($this->form_validation->run() == FALSE){
//error in the form
}else{
//no error in the form
}
}