Gets hash of given string.
Parameters
$data
stringrequired- Plain text to hash.
$scheme
stringoptional- Authentication scheme (auth, secure_auth, logged_in, nonce).
Default:
'auth'
Source
function wp_hash( $data, $scheme = 'auth' ) {
$salt = wp_salt( $scheme );
return hash_hmac( 'md5', $data, $salt );
}
Changelog
Version | Description |
---|---|
2.0.3 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.