Version: 1.00, by TWTCommish
Developer Last Online: Dec 2022
Version: 2.2.x
Rating:
Released: 05-12-2002
Last Update: Never
Installs: 75
No support by the author.
This hack is pretty straightforward: it provides more detail on the Who's Online? page. Here are some examples:
Things like "Editing Buddy List" or "Editing Forum Options" are not accompanied by links. "Buddy List" links to the page to edit your own Buddy List, and so on with "Forum Options, "Ignore List," and a few others similar to that.
Instead of "Sending Email to Another Forum User" or "Viewing the Profile of a Forum Member," you'll be told which user it is in both cases, and their username will be a link to their profile.
Most significantly, IMO: no more vague "Sending Private Message" or "Reading Private Message" messages. Now you have the following: -- Reading a Private Message -- Reading a Private Message From You -- Replying to a Private Message -- Replying to Your Private Message -- Sending a Private Message -- Sending a Private Message to You
As you can see, this is much more useful, yet it still protects the basic privacy of each member. Cool, eh?
"Viewing the Results of a Poll" now links you to the results of that poll, and the word "Post" in "Editing Post" is a link to the post being edited.
The word "Attachment in "Viewing Attachmet in Thread Blah Blah Blah" is now a link to the specific attachment being viewed.
It is *HIGHLY* recommended that you use vBHacker to install this hack, as it involves 14 code edits in one file (online.php)...automating that can save you a lot of time. Attached is an archive containing a vBHacker installation file, as well as a plain text instruction file. Enjoy.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
I've got it working on 2.2.7 for the most part. The only problem is whenever it shows "Viewing Profile of xxx", it doesn't properly link to the user's profile. It just links to /forum/member.php?s=&action=getinfo&userid=. Anyone else having this problem or know how to fix it?
Has anyone else noticed that upgrading to 2.2.9 breaks the Who's Online for Viewing (this members) Profile ?
EDIT: // as in it was working fine afaik before the upgrade but now I seem to have the following error whenever I try to view a Profile and then look @ Who's Online ...
Code:
Fatal error: Call to a member function on a non-object in /my/home/directory/forums/online.php on line 122
Line 122 is from this hack and comprises
PHP Code:
case 'getinfo':
$userid = explode('userid=', $userinfo[location]);
/*122 */ $user = $DB_site->query_first("SELECT userid, username FROM user WHERE userid = ".intval($userid[1]));
if ($user[username] && $user[userid]) {
$userinfo[where] = "Viewing Profile of <a href=\"member.php?s=$session[sessionhash]&action=getinfo&userid=$user[userid]\">$user[username]</a>";
} else {
$userinfo[where] = "Viewing Profile of a Forum Member";
}
break;
Any ideas what's wrong ?
//EDIT: Apart from me not reading thru the thread properly LOL Sorry!
function show($userinfo) {
global $thread, $post, $forum, $event, $gotforum, $hideprivateforums, $bbuserinfo, $timeformat, $displayemails, $enablepms, $bbtitle, $usergroupdef, $numberguests;
If it doesnt have $DB_site in global then add it such as:
PHP Code:
function show($userinfo) {
global $thread, $post, $forum, $event, $gotforum, $hideprivateforums, $bbuserinfo, $timeformat, $displayemails, $enablepms, $bbtitle, $usergroupdef, $numberguests,$DB_site;
then find:
PHP Code:
case 'mail':
$user = explode('userid=', $userinfo[location]);
if (intval($user[1])) {
$user = $DB_site->query_first("SELECT username FROM user WHERE userid = ".intval($user[1]));
and change it to:
PHP Code:
case 'mail':
$user = explode('userid=', $userinfo[location]);
if (intval($user[1])) {
$user = $DB_site->query_first("SELECT username,userid FROM user WHERE userid = ".intval($user[1]));
now find:
PHP Code:
case 'getinfo':
$userid = explode('userid=', $userinfo[location]);
$user = $DB_site->query_first("SELECT username FROM user WHERE userid = ".intval($userid[1]));
and change it to:
PHP Code:
case 'getinfo':
$userid = explode('userid=', $userinfo[location]);
$user = $DB_site->query_first("SELECT username,userid FROM user WHERE userid = ".intval($userid[1]));
Now every thing should work correctly.
Im also using vbulletin 2.2.9
Originally posted by Boofo Does it make a difference what order the username and userid is on on the query statement? I have the following query in my online.php:
PHP Code:
$user = $DB_site->query_first("SELECT userid, username FROM user WHERE userid = ".intval($userid[1]));
no it doesnt make a difference, i installed this hack on a vbulletin 2.2.9 and when i went to whos online i got quite a bit of errors that as i read through the thread, many others had encountered so i posted the changes i made to fix the errors i was getting.