I have a block of code that checks the variables of a form
For some reason the strlen($fname) and strlen($lname) keep sending down to the else. I have data in the variables. I cannot figure out what the issue is.
Code:
if(strlen($fname > 0) && strlen($lname > 0) && ereg("[0-9]{3}-[0-9]{3}-[0-9]{4}",$phone) && ($email == $email2)){
registerUser($fname, $lname, $street, $city, $state, $zip, $phone, $phone2, $store, $email, $email2);
}else{
echo 'You have a problem''
}
For some reason the strlen($fname) and strlen($lname) keep sending down to the else. I have data in the variables. I cannot figure out what the issue is.