I’m trying to get the username that is signed in, but it wont work. Check this:
I’ve tried:
echo $_SESSION['username'];
and I just get the
error: Notice: Undefined index: username
I know I have a ‘variable’ that is named username…
And i’ve also tried:
echo $_GET['username'];
but that wont work either, same error.
And i have session_start() and I have signed in to the database
You need first aid. In php that is print_r
print_r will show the hole session array if username is not there, you must asign a value first to it