vBulletin Mods

The Official vBulletin Modifications Site
https://www.vbulletin.org/forum/showthread.php?t=325076

Forum Section Ban - By Technidev
by Dave
13 May 2017 16:15

2 Attachment(s)
Mark as installed = get support!

Information
Sometimes there are users who keep ignoring warnings or keep trolling in a specific forum section, maybe it's not worth a forum ban so you want to give them a ban from that specific forum section only.

This plugin will make it possible to ban specific users from specific forum sections. By default, vBulletin only makes it possible for administrators to block a users access to specific forum sections through access masks.

The following settings are present in this plugin:
  • Select which specific usergroups can ban users in all forum sections.
  • Enable whether regular moderators who have powers in specific forum sections can ban people from these forum section.
  • Choose whether:
    • Ban only from forumdisplay. (can still see thread contents in forum section)
    • Ban from forum section and threads in the forum section.
    • Ban from threads in the forum section. (can still see forumdisplay)

So how do I ban someone from a forum section?
In a thread, simply click on the username in the postbit of the user you want to ban and click on the issue ban button.
Anyone who has permission to ban people from forum sections can not be banned by others from the forum section.

You can unban someone from a forum section the same way.

https://www.vbulletin.org/forum/external/2017/05/2.png

Installation
1. Upload files in UPLOAD folder to root of your forum.
2. Import the XML file in the IMPORT folder.
3. Go to AdminCP > Settings > Options > Forum Section Ban - Technidev > configure to your needs.

Upgrade
If you want to upgrade from a previous version then all you have to do is re-upload the files in the UPLOAD folder.

Version History
1.0: Initial release.
1.1: Fixed bug of table name not existing when you use a table prefix.

Extra
Mark as installed = get support!

CAG CheechDogg 13 May 2017 18:30

Will this work on all 4.x versions or just 4.2 ?

Dave 13 May 2017 18:33

Quote:

Originally Posted by CAG CheechDogg (Post 2586479)
Will this work on all 4.x versions or just 4.2 ?

It should work on all of them, but since I only tested it on 4.2.* I can't guarantee that it will work properly on all previous versions.

CAG CheechDogg 13 May 2017 22:26

Good stuff my Man thank you !

Alan_SP 14 May 2017 13:00

Nice. And very useful! :up:

BrettC Frontier 17 May 2017 17:49

Quick question,

"Ban from threads in the forum section. (can still see forumdisplay)"

Does this include the ability to ban/suspend users from viewing a single thread, or all threads?

Dave 17 May 2017 18:06

Quote:

Originally Posted by BrettC Frontier (Post 2586626)
Quick question,

"Ban from threads in the forum section. (can still see forumdisplay)"

Does this include the ability to ban/suspend users from viewing a single thread, or all threads?

That option will ban the user from all threads that belong in the forum section.
However, they can still see forumdisplay, the page that lists all the threads.

This plugin is not used to ban someone from a single thread. You can use this plugin for that: https://www.vbulletin.org/forum/showthread.php?t=259017

migratoria 18 May 2017 12:09

Where can I see a list of banned users?

alcazarx 18 May 2017 13:25

Quote:

Originally Posted by migratoria (Post 2586639)
Where can I see a list of banned users?

Would be nice indeed to have an overview which users are excluded from which forum, yes.
As the others said, nice useful addon :cool:

Dave 18 May 2017 16:30

Quote:

Originally Posted by alcazarx (Post 2586641)
Would be nice indeed to have an overview which users are excluded from which forum, yes.
As the others said, nice useful addon :cool:

I'll work on a new version that has a page in the AdminCP to overview all bans.

Pimp of Pimps 18 May 2017 18:55

When I put up the .xml it makes it so we get a database error whenever we enter a thread. Any ideas?

Dave 18 May 2017 18:58

Quote:

Originally Posted by Pimp of Pimps (Post 2586660)
When I put up the .xml it makes it so we get a database error whenever we enter a thread. Any ideas?

Could you paste the database error (hide any sensitive information such as the IP, database name, etc.) here?

Pimp of Pimps 19 May 2017 15:22

Quote:

Originally Posted by Dave (Post 2586661)
Could you paste the database error (hide any sensitive information such as the IP, database name, etc.) here?

Quote:

Database error in vBulletin 4.2.3:

Invalid SQL:

SELECT
post.*, post.username AS postusername, post.ipaddress AS ip, IF(post.visible = 2, 1, 0) AS isdeleted,
user.*, userfield.*, usertextfield.*,
icon.title as icontitle, icon.iconpath,
avatar.avatarpath, NOT ISNULL(customavatar.userid) AS hascustomavatar, customavatar.dateline AS avatardateline,customavatar.width AS avwidth,customavatar.height AS avheight,
spamlog.postid AS spamlog_postid,
deletionlog.userid AS del_userid, deletionlog.username AS del_username, deletionlog.reason AS del_reason,

editlog.userid AS edit_userid, editlog.username AS edit_username, editlog.dateline AS edit_dateline,
editlog.reason AS edit_reason, editlog.hashistory,
postparsed.pagetext_html, postparsed.hasimages,
sigparsed.signatureparsed, sigparsed.hasimages AS sighasimages,
sigpic.userid AS sigpic, sigpic.dateline AS sigpicdateline, sigpic.width AS sigpicwidth, sigpic.height AS sigpicheight,
IF(user.displaygroupid=0, user.usergroupid, user.displaygroupid) AS displaygroupid, infractiongroupid

, td_sectionban.id AS issectionbanned
FROM vb4_post AS post
LEFT JOIN vb4_user AS user ON(user.userid = post.userid)
LEFT JOIN vb4_userfield AS userfield ON(userfield.userid = user.userid)
LEFT JOIN vb4_usertextfield AS usertextfield ON(usertextfield.userid = user.userid)
LEFT JOIN vb4_icon AS icon ON(icon.iconid = post.iconid)
LEFT JOIN vb4_avatar AS avatar ON(avatar.avatarid = user.avatarid) LEFT JOIN vb4_customavatar AS customavatar ON(customavatar.userid = user.userid)
LEFT JOIN vb4_spamlog AS spamlog ON(spamlog.postid = post.postid)
LEFT JOIN vb4_deletionlog AS deletionlog ON(post.postid = deletionlog.primaryid AND deletionlog.type = 'post')
LEFT JOIN vb4_editlog AS editlog ON(editlog.postid = post.postid)
LEFT JOIN vb4_postparsed AS postparsed ON(postparsed.postid = post.postid AND postparsed.styleid = 55 AND postparsed.languageid = 1)
LEFT JOIN vb4_sigparsed AS sigparsed ON(sigparsed.userid = user.userid AND sigparsed.styleid = 55 AND sigparsed.languageid = 1)
LEFT JOIN vb4_sigpic AS sigpic ON(sigpic.userid = post.userid)

LEFT JOIN vb4_td_sectionban ON (post.userid = td_sectionban.userid AND 5 = td_sectionban.forumid)
WHERE post.postid IN (01601609,1601610,1601611,1601623,1601637)
ORDER BY post.dateline;

MySQL Error : Unknown column 'td_sectionban.id' in 'field list'
Error Number : 1054
Request Date : Friday, May 19th 2017 @ 03:20:55 PM
Error Date : Friday, May 19th 2017 @ 03:20:55 PM
Script : http://www.millenniumforums.com/show...ello&p=1601637
Referrer : http://www.millenniumforums.com/forum.php
IP Address : 173.66.155.203
Username : Pimp of Pimps
Classname : vB_Database_MySQLi
MySQL Version : 5.6.35
Here you go

Dave 19 May 2017 15:38

Thanks. I uploaded a new version (1.1) that should fix that bug.
Let me know if it fixes it.

Pimp of Pimps 20 May 2017 13:56

Quote:

Originally Posted by Dave (Post 2586685)
Thanks. I uploaded a new version (1.1) that should fix that bug.
Let me know if it fixes it.

Yes, it's working great now. Thanks!


All times are GMT. The time now is 22:42.

Powered by vBulletin® Version 3.8.12
Copyright © 2019, MH Sub I, LLC dba vBulletin. All Rights Reserved. vBulletin® is a registered trademark of MH Sub I, LLC
Copyright ©2001 - , vbulletin.org. All rights reserved.