![]() |
yeah, this script "works" but it doesnt really work.
for example when i have 60 users online it says there are 120, and it keeps going up, and then every now and then it will drop down to the actual number.. any ideas..? |
I think the online vbulletin script works with cookies and with a timeout option. The onlinescript by Slip counts all userid's in "session". So the results are different.
Compare in index.php from vbulletin: Code:
if ($displayloggedin) { |
would anyone mind telling me how to implement that?
sorry, i'm incredibly stupid when it comes to PHP stuff.. |
Well, you could require() the global.php file and then you could use the $cookietimeout variable. Or you could pull it from the database yourself, either way (it's in the settings table, I believe). :) But then, you would adjust the code:
Code:
<? |
That's what I thought, and it got rid of the cumulative effect of the previous code.
But now it insists there are 0 people online :( |
Is it possible to add the number of "guests" currently online as well?
Thanks :) -Hideki |
anyone want to help with fixing this?
|
I have been looking at it...give me some time..
|
It would be coool if it actually showed the members (who)that are online like index.php
|
OK I think I goofed. I looked at the sessions table, so here goes.
For registered members, you need it where userid>0. For guests, it's where userid=0. So let's revisit the code: Code:
<? I also added a couple lines to set the date cut without involving global.php. Use $membersonline to display the members online, and use $guestsonline to display the guests. |
All times are GMT. The time now is 09:49 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|