cant override session variables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



 
Hi all,

This is drving me insane...

I have a logout script, logout.php:

<?

$_SESSION['validlogin']="";

$_SESSION['username']="";

$_SESSION['password']="";

unset($_SESSION['validlogin']);

unset($_SESSION['username']);

unset($_SESSION['password']);

session_unset();

print("username=".$_SESSION['username']);

print("password=".$_SESSION['password']);



if(session_id()){

session_destroy();}

?>

that effectively cleans the session variables.

However, when i try to set them again, they won't take

the new values:

<?

session_start();

 

$_SESSION['validlogin']=true;

$_SESSION['username']=$username;

$_SESSION['password']=$password;



print("username_session ".$_SESSION['username']);

exit();

?>

 will print: username_session blank...

I know globals are on...what's a happening? why the

variables are cleaned fine why there's no override?

tia, 

lizet

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux