Uutiset:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu
Advertisement:

using SSI to load who's online into an array

Aloittaja FiNCH, helmikuu 26, 2006, 04:24:48 IP

« edellinen - seuraava »

FiNCH

Okay i've been at this all day, all i'm trying to do is load the whosOnline(); function into an array and simply display the number of people online, including guests, members, hidden...every possible user.

Can someone help me out with this?

kegobeer

Have you reviewed the SSI Basic, Advanced, and Expert threads?  They show how to call a function and get the data instead of merely echoing the data.


$users = ssi_whosOnline('array');


You can look at the whosOnline function and see what data is returned into the array (things like id, username, group, etc), and then you can write the code to output only what you want.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

FiNCH

bleh i don't know what i did...

i couldn't see this part of the array before *shrugs*

    [guests] => 0
    [hidden] => 0
    [buddies] => 0
    [num_users] => 1
    [total_users] => 1


thanx for the help, i just needed to step back, take a deep breath and think for 5 seconds :P


Advertisement: