set_logged_in_cookie хук-событие . WP 2.6.0
Fires immediately before the logged-in authentication cookie is set.
Использование
add_action( 'set_logged_in_cookie', 'action_function_name_2364', 10, 6 ); function action_function_name_2364( $logged_in_cookie, $expire, $expiration, $user_id, $scheme, $token ){ // action... }
- $logged_in_cookie(строка)
- The logged-in cookie.
- $expire(число)
- The time the login grace period expires as a UNIX timestamp.
По умолчанию: 12 hours past the cookie's expiration time - $expiration(число)
- The time when the logged-in authentication cookie expires as a UNIX timestamp.
По умолчанию: 14 days from now - $user_id(число)
- User ID.
- $scheme(строка)
- Authentication scheme.
По умолчанию: 'logged_in' - $token(строка)
- User's session token to use for this cookie.
Заметки
- C версии 4.9.0 The
$token
parameter was added.
Где вызывается хук
set_logged_in_cookie
wp-includes/pluggable.php 907
do_action( 'set_logged_in_cookie', $logged_in_cookie, $expire, $expiration, $user_id, 'logged_in', $token );