salt
Filters the WordPress salt.
Использование
add_filter( 'salt', 'wp_kama_salt_filter', 10, 2 );
/**
* Function for `salt` filter-hook.
*
* @param string $cached_salt Cached salt for the given scheme.
* @param string $scheme Authentication scheme. Values include 'auth', 'secure_auth', 'logged_in', and 'nonce'.
*
* @return string
*/
function wp_kama_salt_filter( $cached_salt, $scheme ){
// filter...
return $cached_salt;
}
- $cached_salt(строка)
- Cached salt for the given scheme.
- $scheme(строка)
- Authentication scheme. Values include 'auth', 'secure_auth', 'logged_in', and 'nonce'.
Список изменений
| С версии 2.5.0 | Введена. |
Где вызывается хук
salt
wp-includes/pluggable.php 2591
return apply_filters( 'salt', $cached_salts[ $scheme ], $scheme );
wp-includes/pluggable.php 2691
return apply_filters( 'salt', $cached_salts[ $scheme ], $scheme );