if ($SESSION['status'] == "admin") { echo $SESSION['status']; } else { header("Location: index.php?" .SID); }
it returns '0';
how is it possible????
It isn't. Can we see all of the code?
Its a simple function that returns 'admin' if the person is a admin and '0' if its not. I still not sure how is it possible to have that result.
$_SESSION['status'] = checkstatus($username);