代码:
/**
* return bool
**/
function is_email($email)
{
$pattern = "/^[^_][\w]*@[\w.]+[\w]*[^_]$/";
if(preg_match($pattern, $email, $matches)){
return true;
}
return false;
}
代码:
/**
* return bool
**/
function is_email($email)
{
$pattern = "/^[^_][\w]*@[\w.]+[\w]*[^_]$/";
if(preg_match($pattern, $email, $matches)){
return true;
}
return false;
}