Back to vBulletin 3.0 Add-Ons

Ban Ignored/Specified Users from Replying v2.0
Mod Version: 1.00, by magnus

This modification is in the archives.
vB Version: 3.0.0 Rating: (0 vote - 0 average) Installs: 15
Released: 28 Jan 2004 Last Update: Never Downloads: 6
Not Supported  

Ban Ignored/Specified Users from Replying v2.0

Description
This hack will prevent ignored users from replying to your threads, as well as give you the option to ban additional users without adding them to your ignore list.

Information
This hack was previously titled "User-Defined Posting Bans (Ban specified users from replying)"

Tested on RC4, should work on RC1+

Version History
v1.0 - Initial Release
v2.0 - Added auto-ban of ignored users, created installer script for convenience

Click here for upgrade instructions from 1.0!

Spoiler (click to open)


UPGRADE FROM 1.0 INSTRUCTIONS

In NEWTHREAD.PHP:

Find:
PHP Code:
    $posticons construct_icons(intval($newpost['iconid']), $foruminfo['allowicons']); 
Add BELOW:
PHP Code:
    // get ignore ids
    
if ($bbuserinfo['ignorelist'])
    {
        
$ignore_ids explode(' 'trim($bbuserinfo['ignorelist']));
    }
    else
    {
    
$ignore_ids = array();
    }

    
$listusers = array();
    if (!empty(
$ignore_ids))
    {
        
$users $DB_site->query("
            SELECT userid, username FROM " 
TABLE_PREFIX "user
            WHERE userid IN (" 
implode(','$ignore_ids) . ")
            ORDER BY username
        "
);
        while (
$userinfo $DB_site->fetch_array($users))
        {
            if (
$userinfo['userid'] != 0)
            {
                if (
in_array($userinfo['userid'], $ignore_ids))
                {
                    
$listusers['ignore']["$userinfo[userid]"] = $userinfo['username'];
                }
            }
        }
    }

    
$ignore_listbits '';
    if (!empty(
$listusers['ignore']))
    {
        
$_usercount 0;
        foreach (
$listusers['ignore'] AS $userid => $username)
        {
            
$_usercount++;
            if (
$_usercount 1)
            {
                eval(
'$ignore_listbits .= ",$username";');
            } 
            else
            {
                eval(
'$ignore_listbits .= "$username";');
                }                
        }
    } 
In (template) NEWTHREAD:

Find:
HTML Code:
					<input type="text" class="bginput" size="25" name="bannedposters" id="$bannedposters" tabindex="1" /></label></div>
REPLACE with:
HTML Code:
					<input type="text" class="bginput" size="25" name="bannedposters" id="$bannedposters" value="$ignore_listbits" tabindex="1" /></label></div>

Close


Planned Features
v3.0
- Who knows? You tell me.

If you use this, please click

Download

This modification is archived and cannot be downloaded.

Screenshots

 

Similar Mods

Show Thread Enhancements AJAX: Show Users Browsing Threads & Replying vBulletin 3.6 Add-ons

vblts.ru supports vBulletin®, 2022-2024