Nameless icon indicating copy to clipboard operation
Nameless copied to clipboard

Session username

Open zTryhqrd opened this issue 10 years ago • 1 comments

Template:

  • What kind of issue is it (Question, Bug, etc.)? Question
  • In which version of NamelessMC did it occur (1.x.x)? Latest, 1.1.10

Hello, I am currently making a staff page integrated with NamelessMC and PermissionsEx, it's working well but I need to get the session username somehow, I already tried:

  • $_SESSION['user'] which outputs '1' or '0', if session is active.
  • $_SESSION['username'] no output.
  • $_SESSION['name'] no output.
  • $_SESSION['mcname'] no output.
  • $_SESSION['mc'] no output.

And I know that it is used as htmlspecialchars($user->data()->mcname) but I am making a clean PHP page, so I really don't know how to use those formats.. I'm still a learning PHP "developer".

zTryhqrd avatar Jul 24 '16 09:07 zTryhqrd

Or does someone know how I can use the $user->data()->mcname things and what file I need to include to my own clean PHP page.

zTryhqrd avatar Jul 24 '16 12:07 zTryhqrd