Welcome Guest, Not a member yet? Register   Sign In
Storing session information in permanent cookie
#10

Taken from the PHP manual
http://php.net/manual/en/function.setcookie.php

Quote:expire

The time the cookie expires. This is a Unix timestamp so is in number of seconds since the epoch. In other words, you'll most likely set this with the time() function plus the number of seconds before you want it to expire. Or you might use mktime(). time()+60*60*24*30 will set the cookie to expire in 30 days. If set to 0, or omitted, the cookie will expire at the end of the session (when the browser closes).

A non-persistent cookie remains valid for as long as the browser remains open.

Without a cookie there is no way to match it to the session on the server.
And you wouldn't use the PHP session cookie for an authentication now would you?
Reply


Messages In This Thread
RE: Storing session information in permanent cookie - by Martin7483 - 06-23-2017, 05:28 AM



Theme © iAndrew 2016 - Forum software by © MyBB