I manage a WordPress site hosted at WPEngine that was recently force-upgraded to version 3.6. The upgrade introduced “In-line login following expired sessions”, and therein lies the problem. The website is used to manage registrations, room assignments, and other similar functions for a resort. This means that WordPress is often left open, but not actively used, for hours at a time. Before 3.6 everything was fine, but now the client is complaining about the new login modal popping up “often” (every 2-3 minutes or every 20 minutes, depending on who is asked).
My question in short: How do you disable or extend the session responsible for this new modal window?
I have tried using the auth_cookie_expiration
filter, but this only seems to effect being logged out between page loads and has no effect on the in-line login window.
Full code of what I tried:
function myplugin_cookie_expiration( $expiration, $user_id, $remember ) {
// If the "Remember Me" box is checked, keep the session for 14 days. Otherwise
// only keep the session for 2 hours
return $remember ? 1209600 : 7200;
}
add_filter( 'auth_cookie_expiration', 'myplugin_cookie_expiration', 99, 3 );
There seems to be question similar to this already posted, but there was no response… Thanks in advance for any insight you can offer!
It finally hit me that javascript would be behind the interim login modal behavior, and that gave me a new direction in my search. I have disabled the new login popups by adding the following to my theme’s
functions.php
file:If anyone’s interested in learning more about the new login modals, they are setup in
wp-includes/functions.php
starting on line 3929. You should be able to derive the names and locations of supporting files from the information found there.