Session cookie setting being set while session is active

Trying to do will raise a warning since PHP 7.2, and it never worked as intented.
See: https://bugs.php.net/bug.php\?id\=75650
This commit is contained in:
ArthurHoaro 2020-01-23 19:51:14 +01:00
parent 57bd9780c8
commit 09390a50cd

View file

@ -243,7 +243,9 @@ if (isset($_POST['login'])) {
}
// Send cookie with the new expiration date to the browser
session_destroy();
session_set_cookie_params($expirationTime, $cookiedir, $_SERVER['SERVER_NAME']);
session_start();
session_regenerate_id(true);
// Optional redirect after login: