Version: 1.00, by Grendel602
Developer Last Online: Jan 2003
Version: 2.2.x
Rating:
Released: 12-24-2002
Last Update: Never
Installs: 45
No support by the author.
This is our first hack, but it works very nicely.
This hack changes the way a user is displayed as online or offline when viewing a thread. It serves three purposes. One, it cuts down on a cluttered postbit. Two, it makes it very easy to distinguish who?s online and who?s not when viewing a thread. Three, it?s kinda cool.
If a user is offline his/her avatar?s opacity will be set to 20 (This is the setting we are using, you can change this number by editing the ?postbit_avataroffline? template, which is included in the attached zip file). A low image opacity gives an image a washed out sort of look. If a user is Online his/her avatar?s opacity is 100 of course.
This hack is fairly easy to install. You?ll have to edit three php files, add a new template, edit your ?Head Insert? under Styles, upload a small Javascript file, and make a small change to your postbit, announcement, and privmsg templates.
Included in the zip file is an install.txt document and one javascript file.
Creativity by Grendel
Coding by Nomb
BTW, This is the Official Merry Christmas Hack!
Don't forget to click install if you use this hack.
Merry Christmas.
**EDIT** (12/25/02 6:00 pm EST)
I've updated the install file. Users that don't have avatars will stay that way. Also, the coding is integrated into whether or not users select the option to "show" avatars or not.
Final release!
I will be adding something else to this hack in the future. For now, it works with no weird stuff.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Thanks. It's worked out quite well for us. The other thing you could do, I might, is make a default avatar (Something to do with your site, your logo maybe) and have vB assign it to new members until they choose one of their own. This way, you'd know if they were online or not.
Thanks. It's worked out quite well for us. The other thing you could do, I might, is make a default avatar (Something to do with your site, your logo maybe) and have vB assign it to new members until they choose one of their own. This way, you'd know if they were online or not.
Yea, I already implemented something similar at our boards. We are just using the noavatar.gif.
Here's a snippit of the code for admin/functions.php, although, you should edit private.php and announcement.php as well.
PHP Code:
if ($post[avatarid]!=0) {
$avatarurl=$post[avatarpath];
} else {
if ($post[hascustomavatar] and $avatarenabled) {
$avatarurl="avatar.php?userid=$post[userid]&dateline=$post[avatardateline]";
} else {
$avatarurl="images/avatars/noavatar.gif";
}
}
if ($bbuserinfo[userid]>0 and !($bbuserinfo[showavatars])) {
$post[avatar]="";
} else {
if ($post['lastactivity'] > $datecut and !$post['invisible'] and $post['lastvisit'] != $post['lastactivity']) {
eval("\$post[avatar] = \"".gettemplate("postbit_avatar")."\";");
} else {
eval("\$post[avatar] = \"".gettemplate("postbit_avataroffline")."\";");
}
}
Using this your members will have a "no avatar selected" avatar if they haven't used a custom avatar and it will still function like the others (Online/Offline low opacity status).
I'll probably update the hack later but I don't have time right now. :P
Here's the noavatar.gif file which should be placed in images/avatars/