Back to vBulletin 3.7 Add-ons

Userlog on profile - Display namechanges,bans and email changes
Mod Version: 1.2, by zappsan

This modification is in the archives.
vB Version: 3.7.0 Rating: (4 votes - 4.50 average) Installs: 131
Released: 20 Apr 2008 Last Update: 21 Jun 2008 Downloads: 615
Not Supported Uses Plugins  

What does this do?

This hack will display changes which have been made to the user's account (currently bans, username changes and email changes) in an additional tab in the user profile. It should make it easier for users to keep track of changes applied to someone's account (especially name changes).

Instructions

Simply import the userlogs_on_profile product and you should be done.

Notes
  • The hack will add one new template (memberinfo_block_userlog)
  • For displaying the bans of someone, the hack will assume the usergroup for banned members is usergroup number 8 (default banned group on a fresh vB installation). If your banned group has a different ID, you can change it in the adminCP (Userlog on Profile Settings).
  • All changes made using vB 3.6 or any lower version won't be displayed, since the userlog feature was first introduced in 3.7
  • If there are no entries for someone, the tab won't be displayed on their profile.

Updates

[21/6/2008] Version 1.2:
-The hack now also displays email changes (can be turned off)
-The hack now uses only one query instead of 3
-Applied some of the suggestions from Kentauros in this post

Spoiler (click to open)


Thanks. Nice hack.

Some comments:

Instead of
$userid=intval($_GET[u]);
You should use:
$userid = $this->profile->userinfo['userid'];

========

Instead of
mysql_fetch_array(
you should use
$db->fetch_array(

========

Instead of
$vbulletin->db->
you should use
$this->registry->db->

anything $vbulletin-> could be accomplished with $this->registry
and you eliminate the use of a global variable and instead use the encapsulated class reference

========

The template is not cached. That is an additional query in all profiles. Add a pluging for 'cache_templates' with this code:

Code:
if (THIS_SCRIPT == 'member')
{
    $globaltemplates[] = 'memberinfo_block_userlog';
}

Close


[22/4/2008] Version 1.1:
Added AdminCP settings:
-Option to turn the namechangelog or banlog on/off
-Option to only allow certain usergroup to see the banlogs/namechangelogs
-Option to set the ID of the banned group

[20/4/2008] Version 1.0:
First release

Download

This modification is archived, downloads are still allowed.

File Type: %1$s userlog_on_profile_1.2.zip (2.7 KB, 471 downloads)

Screenshots

Click image for larger version
Name:	userlog.png
Views:	763
Size:	7.6 KB
ID:	82730   Click image for larger version
Name:	userlog_on_profile_acp.png
Views:	262
Size:	35.2 KB
ID:	82731  


vblts.ru supports vBulletin®, 2022-2024