PDA

View Full Version : Who's Online Stealth (Micro?)-Hack


Moonwolf
01-11-2002, 10:00 PM
(AKA Nosey Bugger Blocker :) )

This is an expansion on Firefly's mod to online.php

It'll allow you to individually set Admins, Super Mods, and Mods, to not show their activity in online.php, and allow you to use a default message, or enter a custom one for each group via the control panel.

It might be going out under my name, but since the idea was firefly's, and he fixed my really stupid mistake, he should get most of the credit for it. All I did was kludge :p

To Install: Place the install_stealth.php file in your admin directory, and run it. It'll set up the necessary variables in your control panel, then give you a list of changes to make to your online.php file. Once you've got it all in place, go to Admin Control Panel -> vBulletin Options -> Who's Online and you can set the appropriate stuff up.

For the text strings that show when a usergroup is stealthed, you can use the following variables in the string:

$bbuserinfo[username] - Prints the name of the user viewing the online list

$userinfo[username] - Prints the name of the admin/super mod/mod being stealthed

You can change the default stealthed message by changing the line in the hack that reads "In The Shadows" in online.php to whatever suits you.

Demo: http://www.underlight.com/VBB/online.php (when there's an admin or Super Mod online)

Kathi

GeorgeofCS
01-12-2002, 05:34 PM
Great little addition. Only one minor problem is the installer is missing a few line breaks cause some of the lines to add come out as

case 'admin': if($WOLadstr) { $userinfo[where] = $WOLadstr; } else { $userinfo[where] = "No peeking"; } break; case 'smod': if($WOLsmodstr) { $userinfo[where] = $WOLsmodstr; } else { $userinfo[where] = "No peeking"; } break; case 'mod': if($WOLmodstr) { $userinfo[where] = $WOLmodstr; } else { $userinfo[where] = "No Peeking"; } break;

where they should be:

case 'admin':
if($WOLadstr) { $userinfo[where] = $WOLadstr; } else { $userinfo[where] = "No peeking"; } break; case 'smod': if($WOLsmodstr) { $userinfo[where] = $WOLsmodstr; } else { $userinfo[where] = "No peeking"; } break; case 'mod': if($WOLmodstr) { $userinfo[where] = $WOLmodstr; } else { $userinfo[where] = "No Peeking"; } break;

DarkReaper
01-12-2002, 05:38 PM
This is almost what I suggested...:)

Would you be able to make it so you can do it on a per-user basis?

Moonwolf
01-12-2002, 06:27 PM
I always manage to forget -something- :)

Thanks, fixed the installer.

Kathi

Originally posted by GeorgeofCS
Great little addition. Only one minor problem is the installer is missing a few line breaks cause some of the lines to add come out as

case 'admin': if($WOLadstr) { $userinfo[where] = $WOLadstr; } else { $userinfo[where] = "No peeking"; } break; case 'smod': if($WOLsmodstr) { $userinfo[where] = $WOLsmodstr; } else { $userinfo[where] = "No peeking"; } break; case 'mod': if($WOLmodstr) { $userinfo[where] = $WOLmodstr; } else { $userinfo[where] = "No Peeking"; } break;

where they should be:

case 'admin':
if($WOLadstr) { $userinfo[where] = $WOLadstr; } else { $userinfo[where] = "No peeking"; } break; case 'smod': if($WOLsmodstr) { $userinfo[where] = $WOLsmodstr; } else { $userinfo[where] = "No peeking"; } break; case 'mod': if($WOLmodstr) { $userinfo[where] = $WOLmodstr; } else { $userinfo[where] = "No Peeking"; } break;

Lionel
01-12-2002, 06:52 PM
Looks like this hack has no effect when firefly's mini hack "ah ha peeking..." is installed, because this it what it is showing for admin...

Lionel
01-12-2002, 07:09 PM
It works for every other admin and mods, but one: the one who is defined in firefly's mini hack (great hack btw but you'll never find it unless you are nice to him :D ).

Thanks for yours.

fonzerelli_79
01-14-2002, 01:18 AM
top hack

i have a problem though (just a tiny one)

i made the relevant changes to my online.php but then the page didnt work. I think i had a space where i shouldnt. so i decided to start from scratch and make the changes again. to do this i had to install the hack again.

Obviously though this has added the hack twice and i now have two of everything in my options menu.

on top of this, you cant niew where a guest is now

how would i fix this?? :confused:

Moonwolf
01-14-2002, 02:07 PM
Paste this code into a file in your admin directory, then run it, it should clear the extra fields for you. Then run step 1 of the install_stealth.php file to re-add the extra fields.

<?php
require("./global.php");
cpheader();
$DB_site->query("DELETE FROM setting WHERE varname='WOLsadmin'");
$DB_site->query("DELETE FROM setting WHERE varname='WOLadstr'");
$DB_site->query("DELETE FROM setting WHERE varname='WOLsmods'");
$DB_site->query("DELETE FROM setting WHERE varname='WOLsmodstr'");
$DB_site->query("DELETE FROM setting WHERE varname='WOLsmod'");
$DB_site->query("DELETE FROM setting WHERE varname='WOLmodstr'");
echo "Records erased!";
cpfooter();
?>


As for guests being stealthed, I'm not sure. Guests don't have usergroupid's, so they shouldn't get stealthed. Are your guests getting usergroupid 5, 6, or 7? Go to Admin Control Panel -> User Groups -> Modify, put your mouse over the "edit" link of your admins, super mods, and mods groups, and look at the URL that link goes to, the last part of the URL should contain the usergroupid.

Kathi

fonzerelli_79
01-14-2002, 02:18 PM
hey moonwolf
thanks for helping me out

when i run the file i get this error


Invalid SQL: DELETE * FROM setting WHERE varname='WOLsadmin'
mysql error: You have an error in your SQL syntax near '* FROM setting WHERE varname='WOLsadmin'' at line 1


what could this be?

Moonwolf
01-14-2002, 02:35 PM
Fixed, my mistake with the syntax, re-do the snippet I posted above, I've edited it to fix my mistake.

On this one I plead too many meds after a long night of ER hopping :p

Kathi

Originally posted by fonzerelli_79
hey moonwolf
thanks for helping me out

when i run the file i get this error


Invalid SQL: DELETE * FROM setting WHERE varname='WOLsadmin'
mysql error: You have an error in your SQL syntax near '* FROM setting WHERE varname='WOLsadmin'' at line 1


what could this be?

Lesane
01-14-2002, 02:42 PM
Great hack, thanks.

S0uL
01-14-2002, 09:25 PM
ok i have 2 admins on my board. me and another guy. is there a way i can set it so we can each have diffrent messages?

fonzerelli_79
01-14-2002, 10:16 PM
thanks moonwolf

youve bailed me out again :D

Moonwolf
01-15-2002, 03:31 AM
You'd probably be better off using FireFly's version, which works on userid's instead of usergroupid's.

Kathi

Originally posted by S0uL
ok i have 2 admins on my board. me and another guy. is there a way i can set it so we can each have diffrent messages?

cyrus
01-15-2002, 12:25 PM
@ moonwolf

where can fireflys hack for whos online be found ? :confused:

Moonwolf
01-15-2002, 12:46 PM
<a href="https://vborg.vbsupport.ru/showthread.php?postid=197196#post197196" target="_blank">https://vborg.vbsupport.ru/showt...196#post197196</a>

The two hacks, Firefly's original for specific users, and this one for usergroups, should be able to run side by side on the same board.

Kathi

igowoofwoof
01-17-2002, 03:35 PM
what happen if you want to uninstall this hack and try it again...can sombody please tell me how to do this....thank you

Moonwolf
01-18-2002, 02:08 PM
Go to Post #8 (https://vborg.vbsupport.ru/showthread.php?postid=213240#post213240). Follow the instructions about creating a file with the included code, run the file with that code. Remove the lines in online.php that the original installer tells you to add, and you're back to where you started. You should only need to remove the lines in online.php since nothing was replaced in the hack.

Kathi

Rose
01-18-2002, 02:54 PM
I have added your changes, and uploaded. I had a couple errors, but fixed those (my own fault - I added another usergroup).

But, while I no longer receive errors, nothing seems to have changed on the 'who's online'. It still shows everyone like normal.

I created a test user since guests can't view the who's online at my forum. The test user was just a regular member. I had a moderator log onto the board, and I logged in as the test user. But I could still see where the mod was and what they were doing. :(

Moonwolf
01-18-2002, 08:25 PM
Only two things can think of if you're getting this.

You're not uxing the "default" usergroups
Some times you have to submit the admin CP options form twice. (i.e. load it, changer it, submit it, load it again, submit it)

No idea why that second one works :-/

Kathi


Originally posted by Rose
I have added your changes, and uploaded. I had a couple errors, but fixed those (my own fault - I added another usergroup).

But, while I no longer receive errors, nothing seems to have changed on the 'who's online'. It still shows everyone like normal.

I created a test user since guests can't view the who's online at my forum. The test user was just a regular member. I had a moderator log onto the board, and I logged in as the test user. But I could still see where the mod was and what they were doing. :(

Rose
02-26-2002, 05:59 PM
Erm, if one was to accidently install this hack twice, how would you go about uninstalling a part of it? ((I have double the 'fun' (options) in my admin cp - but I dont' know how to go backwards to undo it since I used the installer))

Any suggestions?

Lionel
03-01-2002, 12:37 PM
Can this be made so the admin can see where the mods are?

cditty
03-04-2002, 06:41 AM
Originally posted by Lionel
Can this be made so the admin can see where the mods are?

This is a good idea. I would really like to see this added if possible. Otherwise, good hack.

Chris

mersey
03-06-2002, 08:00 PM
thank you for the hack Moonwolf :)
it would be nice if admins could see the location like the above 2 posts say. but its a nice hack anyway :)

Tungsten
06-18-2002, 01:09 PM
I changed around the code a bit to have some fun with my users... :devious:


$userinfo[where] = "Reading thread <a href='online.php?s=$session[sessionhash]'>Naughty Pics of $bbuserinfo[username]</a>";

Chris M
06-18-2002, 06:14 PM
Lmao...

Good hack...

Satan

Xelation
06-18-2002, 06:47 PM
hmm... $bbuserinfo[username] doesn't seem to work for me... any ideas?

Xelation
06-22-2002, 10:42 PM
how can I uninstall this? I accidently added it to the database twice... any help?

edit: nm, I just went into the database and deleted the extras manually.

Night Owl
07-06-2002, 11:27 PM
I would like to hide the locations of a usergroup that is not a moderator, supermod or admin. How can I do this?

The usergroupid is 9 and the name of the group is sybermom.

ForKmaN
08-12-2002, 11:18 AM
Nice hack! :)

I love it and my users hate it :D

Rose
08-13-2002, 04:24 PM
Originally posted by cditty


This is a good idea. I would really like to see this added if possible. Otherwise, good hack.

Chris


I'd be interested, also. As admin, I'd like to see what the mods are up to. *hehe*

Rose
09-21-2002, 07:14 PM
Bumpity bump bump? Anyone? Please?

*sits with a book*

Talisman
12-31-2002, 10:18 PM
Originally posted by Moonwolf
The two hacks, Firefly's original for specific users, and this one for usergroups, should be able to run side by side on the same board.

Love this hack and Firefly's original change. This is great stuff. (Still need some help with it, though.) I've set up.....

1. Firefly's hack to hardcode a WOL location for specific user (specifically, me). That little goodie can be found in the Lounge here (https://vborg.vbsupport.ru/showthread.php?s=&threadid=31938&perpage=15&display=&pagenumber=1).

2. Next to that, I'm also using this hack (thanks, Moonwolf!).

3. And I took Tungsten's suggestion for the location I'm using.

The problem we're having is regular members and unregistered guests are also be shown with the custom locations. Previously, Firefly gave us code that was supposed to fix that. And I see, Moonwolf included that portion in this hack.

But that didn't fix it.

To make this as easy as possible for you guys to help, I'll show here what the code is. Hope someone can solve this for us.

In online.php ....... before this:

// Let's show the admin the location but put something false up for everyone else..

I have this:

case 'admin':
if($WOLadstr) {
$userinfo[where] = $WOLadstr;
} else {
$userinfo[where] = "Performing site maintenance";
}
break;

case 'smod':
if($WOLsmodstr) {
$userinfo[where] = $WOLsmodstr;
} else {
$userinfo[where] = "Performing site maintenance";
}
break;

case 'mod':
if($WOLmodstr) {
$userinfo[where] = $WOLmodstr;
} else {
$userinfo[where] = "Performing site maintenance";
}
break;

case 'Talisman':
$userinfo[where] = "Viewing Thread <a href='online.php?s=$session[sessionhash]'>Naughty Photos of $bbuserinfo[username]</a>";
break;

The cases for admin, smod, and mod came from this hack and case Talisman came from Firefly/Tungsten.

Then, before this:

if ($onlineloc!='' and $userinfo[activity]=='unknown') {
$onlinelocbits=explode("|||",$onlineloc);
while (list($key,$ourfilename)=each($onlinelocbits)) {
list($key,$text)=each($onlinelocbits);
if ($filename==$ourfilename)
$userinfo[activity] = $ourfilename;
}
}

return $userinfo;
}

I have this:

if ($WOLsadmin && $userinfo[usergroupid]==6) {
$userinfo[activity] = 'admin';
}
if ($WOLsmods && $userinfo[usergroupid]==5) {
$userinfo[activity] = 'smod';
}
if ($WOLsmod && $userinfo[usergroupid]==7) {
$userinfo[activity] = 'mod';
}
if ($userinfo[userid]==2) {
$userinfo[activity] = 'Talisman';
}

(Note: As I wasn't the person who set up our board, my admin userid is 2 instead of 1)

So..... can anyone figure out how our guests and members are showing up on the WOL with these custom locations, too?

Thanks everyone..... please feel free to PM me for more information if you need to.

Cheers!

Talisman
01-04-2003, 04:07 PM
*bump*

Someone, please help with this request? The custom locations set for admins/mods only are showing up for regular members and unregistered guests, as well. I've been through all the related threads and still don't know why.

The fix Firefly offered in his thread (which is included in Moonwolf's hack as well) doesn't prevent this from happening.

Thanks.

Talisman
01-06-2003, 06:56 AM
Don't seem to have much choice .......... uninstalled.

glas
03-05-2003, 12:00 AM
So, I've installed this, however, the option to turn WOL is gone, and somehow they got disabled. I'm figuring the field got erased during the addition.

Also, I ran the code you posted, Kathi, but I got an error. I'm assuming I'm being dumb and that wasn't a query to run, but your directions were a little fuzzy as to what file to paste and run it in. At least to me. :\

Any help would be greatly appreciated.

glas
03-05-2003, 06:54 PM
*cough* Bump.

With every post here, I lose faith in the vb.org team and their ability to help users. Someone mind proving me wrong?

Airs
08-12-2003, 08:21 PM
this is pretty old and all but have a tough problem my forum lost the switch that says Whos online turned on or off..and now its automaticlly turned off..help!.

bexie
12-14-2003, 01:50 AM
this is pretty old and all but have a tough problem my forum lost the switch that says Whos online turned on or off..and now its automaticlly turned off..help!.
Same problem here. I'm running on 2.3.2. Anyone have any suggestions?! Thanks!

simie
02-05-2004, 09:18 AM
running 2.3.2 myself and I also have the prob that Airs and bexie are having. Help!

Wifey
03-20-2004, 10:40 PM
After I installed it, I'm getting this problem that I've attached a screencap of.

Enable Guest and Enable Who's online aren't there as options...

I've even uninstalled and they're still not there anymore...

Edison Chen
04-14-2004, 10:50 AM
Apparently, I failed to do the hack and now, it has disabled my Who's Online. How to make it abled again? I have the same problem as ashkarita had.

Edison Chen
06-10-2004, 01:02 AM
Help? *bumps*

Elzee
08-04-2004, 04:10 PM
I'm also having the same problem... has any one figured out a way to fix it?

Rich
09-15-2004, 10:51 PM
Hello,
I am bumping this up just because there hasn't been a response. I didn't nor will I be installing this because it seems that the original authors have dismissed it.(I would have ported it to VB3) Since the code has somehow disabled some of the members who's online,it would be a courtesy if something was written in this thread that may help them to regain it.

spiritmage
11-28-2004, 09:51 PM
I'm having the same problem... I've ended up disabling my Who's Online... Any ideas how to fix it?

yzztik
05-02-2005, 02:39 AM
Somehow, these 2 lines are overwrite the enable setting:

$DB_site->query("UPDATE setting SET settinggroupid=31,title='Resolve IPs',varname='WOLresolve',value='0',description='R esolve IP addresses for those who have access to view them? This can slow down the Display of Who\'s Online.',optioncode='yesno',displayorder='9' WHERE settingid='169'");

$DB_site->query("UPDATE setting SET settinggroupid=31,title='Refresh',varname='WOLrefr esh',value='60',description='Time period in seconds to refresh the Who\'s Online display. 0 disables refresh.',optioncode='',displayorder='10' WHERE settingid='170'");

To fix it, go to http://www.friends-boards.com/forum/admin/setting.php

Scroll down to the Who's Online category and click [add setting]
Fill in the fields as follows:
Title: Enable Who's Online?
Variable Name: WOLenable
Value: 1
Code to generate option: yesno
Display Order: 1

Gray Matter
05-15-2005, 02:40 AM
That didn't work...

Marco van Herwaarden
05-15-2005, 09:53 AM
You guys do realize that htis is a hack for vB2?

Gray Matter
06-16-2005, 10:29 PM
You guys do realize that htis is a hack for vB2?

Obviously it is. :)

For the other problem that was mentioned, This is how you can enable to see guest activity in WOL again:

Go to yourforums.com/admin/setting.php
Scroll down toward the bottom where you'll see the category "Who's Online".
Hit "[ add setting ]" which appears three links after the WOL text.
Fill in the fields as follows:

Setting Category - Who's Online
Title - Enable Guests
Variable Name - WOLguests
Value - 1
Description - Display Guest activity on Who's Online?
Code to Generate Option - yesno
Display Order - 2

And you're done! Now if you go to "vBulletin Settings" in your Admin CP and scroll down to WOL, you'll be able to enable/disable the logging of guest activity. :)