Cookie changes the value after firefox reopenening
In my website I change a cookie value and a cookie lifetime on POST request. After the cookie is changed my website reloads the page (header: Location {url}). Then if a user will close browser and reopen it the cookie will have the value that was before changing.
Here is a link with php example on stackoverflow: http://stackoverflow.com/questions/28691649/why-this-cookie-changes-value-after-browser-reopening
Here is php code: ini_set('session.cookie_lifetime', 86400); session_regenerate_id(true);
header('Location: http://localhost/sessiontest/'); return;
} print_r($_COOKIE); ?>
<form method="post" action=""> <input type="text" name="test"> <input type="submit"> </form>すべての返信 (2)
You may have to change the defaults for cookie storage. For more details:
guigs2 said
You may have to change the defaults for cookie storage. For more details:
Is it a temp solution? I can't say all my users to change browser's settings. This error occurs only in firefox. In chrome browser it works fine. I think that it is incorrect behavior in firefox. Because of this error users are logged out after browser's reopening.