I’ve used this:
ini_set("session.cookie_lifetime","360000");
session_start();
$_SESSION['valid_user'] = $row['id'];
I don’t have acces to the server settings. I want to keep sessions for a very long time alive, like until 2012.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You wouldn’t be able to keep up sessions until 2012 anyway. If you want something for a long time, that is where cookies can be put to use. You can take a look at
setcookiefunction of php for more information.