PDA

View Full Version : X online users - but on anotehr page


06-04-2000, 01:37 PM
What I would really like to see is a hack that allows you to see how many other members and guests there are online. But not on the same page, for example, on forumdisplay, you can have a little sentence at the top saying: X users online.

06-08-2000, 06:59 PM
Can this be done? Ed?

06-09-2000, 11:00 AM
It should be as simple as putting $loggedinusers wherever you want this displayed in whatever template you want it displayed in.

Unless you don't want the names displayed, just the total head count...?

06-09-2000, 02:12 PM
Yup, just want the head count.

06-09-2000, 02:17 PM
Wow, didn't realize I get asked for hacks :)

Just brainstorming out loud here:

If you wanted to do an online.cgi style thing, I think you'd need to add a profile field like "lastpage" that would give the URL for the last visited page (if you wanted to do it that way)

Or you could just do a simple version that would translate the last visited time to a readable version and display it on its own page... Pretty simple actually.

My next hack maybe? :D

06-09-2000, 09:55 PM
theprof, if you just want a head count and none of the cool stuff Ed mentioned...

Open index.php and go to line 139 - find this:

$numberinvisible=$numberregistered-$numbervisible;
eval("\$loggedinusers = \"".gettemplate("loggedinusers")."\";");
}

and add

$headcount=$numberguest+$numberregistered;

in between the $numberinvisible and eval lines. Then call $headcount from whatever template you want it displayed in.

[Edited by leah r on 06-10-2000 at 06:57 AM]

06-11-2000, 09:43 PM
Prof,

Is this what you want? http://www.gandmasti.com (the ability to display a list of users on another page which is not a part of the forum software?)

I'd posted it on

http://www.vbulletin.com/forum/showthread.php?threadid=958

Shri