Hello all,
I'm making a dashboard kind of a thing for online ticket booking website.
For that I need a list of all the users who are online and if possible, I need to see which page they are on.
I don't know how can I do it. I tried a simple code like this:
$users_list = $users->find();
foreach ($users_list as $u) {
if ($u->isLoggedin()) {
echo $u->name." is Logged in.<br/>";
}
}
Which outputs list of all the users and shows all them online, which is obviously impossible as I'm running this on localhost.
So how do I do it?
p.s.: The logic in code is very wrong, now when I think about it, I know this is not the code I need.