I want to be able to show the current users online. I've found a script that counts the number of active usrs online, however if I modify it slightly to display those user's usernames (by directly reading raw data from the session files) I get no output.
Is access to these files denied due to security issues? And if so what would be the simplist alternative?
Displaying users online using sessions
Moderator: General Moderators
Re: Displaying users online using sessions
Session data is serialized. If that's not the problem maybe you could give us the part of the script that doesn't do what you expect it to do.
Re: Displaying users online using sessions
I figured out the problem, or at least a solution. It seemed I was not able to correctly read the session file after calling session_start(), which I guess makes sense. I simply removed that call in the script and I was able to read the file fine.
Thank you for your help.
Thank you for your help.