Created
November 23, 2019 06:59
-
-
Save jennimckinnon/d39937a0735c03ef855d7bd84a3f4a7a to your computer and use it in GitHub Desktop.
For an article. Source: https://wordpress.stackexchange.com/questions/515/whats-the-easiest-way-to-stop-wp-from-ever-logging-me-out
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'auth_cookie_expiration', 'keep_me_logged_in_for_1_year' ); | |
function keep_me_logged_in_for_1_year( $expirein ) { | |
return YEAR_IN_SECONDS; // 1 year in seconds | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment