I want to logout user if user's sessions are older then 30 mins .is this code correct?
if yes,can somebody explain this please?
if no ,will you tell me whats the problem and solution?
if i wont use this expiry time,site will be unsecure?
if((mktime() - $_SESSION['started'] - 60*30) > 0){
//logout, destroy session etc<br>
}
}else{
$_SESSION['started'] = mktime();
}