Get a numeric user ID from either an email address or a login. If a number is sent to the function, that number is returned as the id.
<?php get_user_id_from_string( $string ); ?>
(string) (必填) String representation of the user to lookup the ID for. May be either the user's login (their username), or the email address registered in WordPress. A numeric string is considered to be an existing user ID and is simply returned as such.
ID of the user specified by $string on success, null if no user is found.