Take a look at the source:
832 if ( $remember ) {
833 /**
834 * Filter the duration of the authentication cookie expiration period.
835 *
836 * @since 2.8.0
837 *
838 * @param int $length Duration of the expiration period in seconds.
839 * @param int $user_id User ID.
840 * @param bool $remember Whether to remember the user login. Default false.
841 */
842 $expiration = time() + apply_filters( \'auth_cookie_expiration\', 14 * DAY_IN_SECONDS, $user_id, $remember );
843
844 /*
845 * Ensure the browser will continue to send the cookie after the expiration time is reached.
846 * Needed for the login grace period in wp_validate_auth_cookie().
847 */
848 $expire = $expiration + ( 12 * HOUR_IN_SECONDS );
849 } else {
850 /** This filter is documented in wp-includes/pluggable.php */
851 $expiration = time() + apply_filters( \'auth_cookie_expiration\', 2 * DAY_IN_SECONDS, $user_id, $remember );
852 $expire = 0;
853 }
Ir“;记住;是否已检查
14 * DAY_IN_SECONDS
, 第842行。如果没有,你有
2 * DAY_IN_SECONDS
, 第851行。
请注意,该函数是可插入的auth_cookie_expiration
过滤器可用于更改这两个值。