I'm trying to get my code to work with register globals off.
I initialize the session var
$_SESSION['usr'] = strtoupper($usr);
Then I include this on every page:
if (!$_SESSION['usr']) {
$_SESSION = array(); // Unset all of the session variables.
session_destroy();
die ("blah blah");
}
The above works fine... but if i change my session var init to:
$_SESSION['usr'] = strtoupper($_SESSION['usr']);
then
if (!$_SESSION['usr']) {...
comes true everytime.