Alright guys heres my problem in my login.php script I have the following:
login.php (top)
session_cache_limiter('must-revalidate');
session_cache_expire(1);
session_start();
echo "***". session_cache_expire()."***";
header("Cache-control: private"); //IE 6 Fix
$UserNameSes = $_SESSION['UserName'];
I use this to ensure that the user is not already logged in, then I move on to seeing if any info was posted from the login form....if so I verify username and password and call this code:
login.php (after verifying username/pass)
session_cache_limiter('must-revalidate');
session_cache_expire(1);
session_start();
$_SESSION['UserName'] = $UserName;
That sets the UserName session variable to the username and the user is redirected to index.php which contains this at the top:
index.php (top)
session_cache_limiter('must-revalidate');
session_cache_expire(1);
session_start();
$UserName = $_SESSION['UserName'];
Now this works all fine and dandy except that the expire time never works whether I set it to 5 minutes or 1 minute it always keeps the user logged in.
Any suggestions?