用于验证电子邮件地址的不推荐使用的功能。
原型
validate_email( string $email, bool $check_domain = true )
参数
$email
(string)
(Required)
电子邮件地址以验证。
$check_domain
(bool)
(Optional)
已过时。
返回值
(string|bool)
虚假或有效的电子邮件地址。
源文件
路径:wp-includes/ms-deprecated.php
<?php
...
function validate_email( $email, $check_domain = true) {
_deprecated_function( __FUNCTION__, '3.0.0', 'is_email()' );
return is_email( $email, $check_domain );
}
...
?>
其他
英文文档:https://developer.wordpress.org/reference/functions/validate_email/