[eluser]aeternuslibertas[/eluser]
awesome thanks!
before i stumbled upon how to correctly check for duplicate emails, i was using this code, that i wrote, and it wasn't working... i spent hours on it, can u see something that i was missing?
Code:
function check_duplicate_email($email){
$continue_registration='';
$q = $this->db->get('realtors');
if($q->num_rows() > 0 ){
foreach ($q->result() as $row){
if($email == $row->email){
$continue_registration=FALSE;
//if $email=$row there is already an exact same email in the system
//so this means we stop the registration process
}//end email if
else if($email!=$row->email){
$continue_registration=TRUE;
//this line returns true, because the submitted email, does not match an email in the system
}
}//end foreach
}//end if
return $continue_registration;
}//end check_duplicate_email