Hi, i am having problems getting the following to work. any help would be appreciated🙂
When a user logs in, it updates the 'last_login' field with the current time of login.
Then, i need to add an if statement (on refresh) to the following code to check to see if the user has been logged on for 30 minutes. If so, then make the user log in again.
So far i have only managed to do the basic session bit, but can anyone tell me how i can modify the following code to be able to do this?
Thanx
Jonathan
======
<?php
session_start();
session_register("logged_in");
if ($logged_in == "1")
{
header("Location: secured_area.php");
} else {
header("Location: login_page.php");
}
?>