To store information in a session that you can use in your application, or specific user information, you do the following:
Code: Select all
session_start();
$_SESSION['firstname'] = $fname ;
$_SESSION['lastname'] = $lname ;
$_SESSION['usercity'] = $city ;
$_SESSION['address'] = $addr ;
Code: Select all
session_start();
$fname = $_SESSION['firstname'] ;
$lname = $_SESSION['lastname'] ;
$city = $_SESSION['usercity'] ;
$address = $_SESSION['address'] ;
Best wishes