Now currently my script uses 'session_register' but according to my friend, thats been depreciated. If this is the case i need to update my code to use $_SESSION, right?
So. I was looking at it and thinking, is this right:
(something along these lines)
Code: Select all
"Check login details are correct, injections/md5 etc etc"
if they are all fine {
$_SESSION['username'] = "True";
header(location: blabla.php);
}
Buuuut i have set a True variable, on the Session in the login script... Gah im confused Haha! Basically can someone explain what is the right way of going about this, the actual setting the session, and then how to check if it is set. Also is there a way to set a session named from a variable?
Thanks!