Version: 1.00, by Darth Cow
Developer Last Online: Feb 2008
Version: 2.2.x
Rating:
Released: 07-21-2002
Last Update: Never
Installs: 43
No support by the author.
On my forums, we give out a custom title at 3000 posts, so it's quite an acomplishment. Of course, the moderators want this too, even though they have to keep their "Moderator" or "Super Moderator" tags as well. Previously we were doing this through the admin panel, but that got a bit tidious, so I did a quick hack that will add moderator custom tags after the "Moderator" bit.
Install time: About 2 minutes - just one file edit
In member.php, after:
PHP Code:
$customtext = substr($customtext, 0, $ctMaxChars);
$customtext = censortext($customtext);
if (!ismoderator() or (ismoderator() and $ctCensorMod==0)) {
$customtext = customcensortext($customtext);
}
Add:
PHP Code:
// Keep user group titles in addition to custom tags for mods
// Add a user group id to the array definition below to make
// this hack apply to that group as well:
$keepgrouptitle = array(5, 6, 7);
if (in_array($bbuserinfo['usergroupid'], $keepgrouptitle)) {
$group = $DB_site->query_first("SELECT usertitle FROM usergroup WHERE usergroupid=$bbuserinfo[usergroupid]");
$usertitle = $group['usertitle'];
$customtext = $usertitle . '<br />' . $customtext;
$customtitle = 1;
}
// Keep user group titles in addition to custom tags for mods
Yep, that's it . Let me know if there are any issues, trouble, ect.
Note: This will enble HTML for moderators in custom tags as well, but you can trust them not to use it. Right? aranoid:
If you use this hack, please hit the "Install" button on this thread so I know .
The latest version is merely a slight modification of the original, to allow for easier addition of user groups. Feel no need to upgrade, it doesn't actually change how the hack works except make it easier to modify.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Well, what do you want? It's pretty simple - it'll just take your default moderator tag, then add a line break and the user's custom tag. In Edit Profile under custom tag, they'll see something like this under their current tag:
I'll have to get back to you guys on this one - we're running 2.2.6, and I'm not the one who owns the license (that's the other webmaster), so I haven't had a look at the source code for 2.2.7 yet. I'll see if he can send it over to me though .
I did this an easier way, just make a custom profile field only Admin Edittable for the Moderator Rank, and put that above the user title in the post bit template...Same idea I guess, and Mods can still edit their titles as well...
Originally posted by Darth Cow I'll have to get back to you guys on this one - we're running 2.2.6, and I'm not the one who owns the license (that's the other webmaster), so I haven't had a look at the source code for 2.2.7 yet. I'll see if he can send it over to me though .
Any news with it ? *is really hoping to be able to use this hack*