In my app.php I have:
'Session' => [
'cookie' => 'app_sid',
'defaults' => 'cake',
'timeout' => 20160, // The session will timeout after 20160 minutes of inactivity
'cookieTimeout' => 20160, // The session cookie will live for at most 2 weeks, this does not effect session timeouts
'autoRegenerate' => TRUE
]
What I want to achieve, is to let the user be logged in regardless of their actions. This means that the user should stay logged in for 2 weeks unless he chooses to manually logout. Closing the browser window should not logout the server.
Right now, when I'm closing the browser window, it logs-out the user.
How can I prevent this?