Session Problem
Posted: Wed Jun 24, 2009 7:25 pm
Hullo,
I'm having a problem with sessions. My user's are having to login twice.
Here's the chunk of my login php file where sessions are assigned:
And then in the *********** file that the login one headers to, one of the first lines of code run is:
Am I just trying to extract the session too quickly after it's initiated? If my users log in again, all works fine.
Thank you.
I'm having a problem with sessions. My user's are having to login twice.
Here's the chunk of my login php file where sessions are assigned:
Code: Select all
if ($arr['Password'] == $pwHashed)
{
session_start();
$_SESSION['FileP'] = strtolower(str_replace(" ","",$arr['SLName']));
$_SESSION['Password'] = $pwHashed;
$_SESSION['Username'] = $uid;
}
else
{
die ("Invalid Password.");
}
header("Location: http://(***************");Code: Select all
extract($_SESSION) or die("<a href='http://*****************'>Log in</a>");Thank you.