【文件属性】:
文件名称:php email邮箱正则
文件大小:52KB
文件格式:PDF
更新时间:2021-01-21 15:35:43
em ema email
1.验证email:
< ?php
if (ereg(/^[a-z]([a-z0-9]*[-_\.]?[a-z0-9]+)*@([a-z0-9]*[-_]?[a-z0-9]+)+[\.][a-z]{2,3}([\.][a-z]{2})?$/i; ,$email)){
echo “Your email address is correct!”;}
else{
echo Please try again!;
}
?>
或
$str = '';
$isMatched = preg_match('/^\w[-\w.+]*@([A-Za-z0-9][-A-Za-z0-9]+\