What's the opposite of triple equals matching in PHP?
$mail_01 = filter_var($mail_01, FILTER_VALIDATE_EMAIL);
if($mail !== false){
echo "Email address required";
}
Is the !==
usage correct?
Thanks for any help.
What's the opposite of triple equals matching in PHP?
$mail_01 = filter_var($mail_01, FILTER_VALIDATE_EMAIL);
if($mail !== false){
echo "Email address required";
}
Is the !==
usage correct?
Thanks for any help.
Yes, !==
is correct. From the manual:
$a !== $b Not identical
TRUE if $a is not equal to $b, or they are not of the same type. (introduced in PHP 4)
Yes, that's correct. a !== b
is logically equivalent to !(a === b)
.