vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Add-On Releases - afterfl0w's Advanced Banlist (https://vborg.vbsupport.ru/showthread.php?t=123800)

afterfl0w 08-11-2006 10:00 PM

afterfl0w's Advanced Banlist
 
afterfl0w's Advanced Banlist! - Version 2.51 :cool:
updated 13/08/06:rolleyes:

Hey all, it's time for another release. This one has been completely re-written and made a lot easier to install! Also, it's vB3.6 and 3.5 compatible!

Onto the buzz:

Features
  • Simple, yet advanced display of banned users
  • Easy-to-set up! 15 minutes or less install time!
  • Import ALL your old bans into this permanent record of banned users!
  • Automatic post edit of offending post, to show warning that the user was banned!
  • Ban types, length, liftdate, bandate all shown on the list
  • Complete support from me, including custom modifications to the banlist
  • ADDED IN VERSION 2.51 - admin_banlist.php section for AdminCP! From there, you can clear the banlist, import bans, and selectively remove bans from the list!
  • ADDED IN VERSION 2.51 - Template edit for postbit that adds easy [Ban User] link!
  • FIXED IN VERSION 2.51 - Fixed Issues with Importing!
  • FIXED IN VERSION 2.51 - [Ban User] link no longer sends the linked page to main
  • FIXED IN VERSION 2.51 - Fixed compatibility errors with the product and showbans.php for older/newer versions of PHP

Quick install, added what everyone wanted, and made it easy to install! What more could you want!

Installation

Upload the product-aft_banlist.xml to your vB products, and then open the included README_FIRST!!.html file, and cycle through the instructions.

Afterwards, upload the showbans.php to your vB root and you're ready to go!

Importing Old Bans

This was HIGHLY requested in the last version, and I'm a fool for not including it.

Upload the import_bans.php file to your admincp folder, and then navigate to, for example, www.site.com/forums/admincp/import_bans.php.

Follow the instructions, which are as easy as pushing a button ;) , and delete the file afterwards!

Upgrading

If you are upgrading, remove the old banlist table and replace all files!

Troubleshooting/Problems

Any problems or issues with this modification can be either posted in this thread, sent to me in a PM or e-mailed to me at flamethrower_stickattack@hotmail.com

You can also add me to MSN and I'll be able to offer support most of the time.

Install and MOTM Votes

I'm not going to force you to hit the install button, or push it on you, but it'd be greatly appreciated if you do! Also, if you REALLY like this hack, please vote it for MOTM(MOD OF THE MONTH) :D

Jesus05uk 08-12-2006 09:55 PM

I'm getting this:
Code:

Database error in vBulletin 3.6.0 Release Candidate 3:

Invalid SQL:
CREATE TABLE banlist (
        banid int(10) unsigned NOT NULL auto_increment,
        userid smallint(5) NOT NULL DEFAULT '',
                usergroupid smallint(5) NOT NULL DEFAULT '',
        username varchar(50) NOT NULL DEFAULT '',
        dateline int(10) unsigned NOT NULL DEFAULT '',
        bannedpost varchar(255) NOT NULL DEFAULT '',
        reason varchar(255) NOT NULL DEFAULT '',
        sentbywhom varchar(50) NOT NULL DEFAULT '',
        howlong int(10) unsigned NOT NULL DEFAULT '',
        INDEX (banid, userid)
                );

MySQL Error  : Invalid default value for 'userid'
Error Number : 1067
Date        : Saturday, August 12th 2006 @ 03:49:32 PM
Script      : http://forums.gmodcentral.com/admincp/plugin.php?do=productimport
Referrer    : http://forums.gmodcentral.com/admincp/plugin.php?do=productadd
IP Address  : 82.44.204.98
Username    : Jesus
Classname    : vb_database


afterfl0w 08-12-2006 10:17 PM

Hmm, I only tested on the full release of vB3.6.

Maybe someone else knows the reason for that? There's nothing wrong with the SQL.

Jesus05uk 08-12-2006 10:26 PM

Quote:

Originally Posted by afterfl0w
Hmm, I only tested on the full release of vB3.6.

Maybe someone else knows the reason for that? There's nothing wrong with the SQL.

Upgrading to Gold now.
Still no luck.

afterfl0w 08-12-2006 10:59 PM

Anyone else having this problem?

EDIT: Jesus, I'm still seeing Powered by vBulletin Version 3.6.0 Release Candidate 3 at the bottom of your forums.

You sure you upgraded? :p

Dan 08-12-2006 11:02 PM

Nice job :)

afterfl0w 08-12-2006 11:53 PM

Update coming soon, since the Import feature appears not to work on an empty database.

iTaLiAnBoY165 08-13-2006 12:10 AM

Hey when i try to import bans i get alot of these errors and then no bans imported.

error:
Warning: Cannot use a scalar value as an array in /admincp/import_bans.php on line 127

afterfl0w 08-13-2006 12:17 AM

Read post above yours. It's being worked on.

Firestar.chkn 08-13-2006 12:49 AM

Hi,

I just installed this. I uploaded the files, made the changes to the bannings.php file, and imported the plugin.

I'm not sure though, if there are some instructions missing. I can see the options section, but I cannot see the ban/unban user section in the postbit.

Also, when I try to import the bans, I get an error message saying that I should be an admin to do it, and that I don't have permissions.

Running 3.6 gold.

Firestar.chkn 08-13-2006 12:50 AM

Sorry, only saw the post now. Thanks :D

iTaLiAnBoY165 08-13-2006 01:02 AM

Sorry didnt refresh before i posted

Tork64 08-13-2006 01:25 AM

lol real cool thx

Jesus05uk 08-13-2006 01:37 AM

Quote:

Originally Posted by afterfl0w
Anyone else having this problem?

EDIT: Jesus, I'm still seeing Powered by vBulletin Version 3.6.0 Release Candidate 3 at the bottom of your forums.

You sure you upgraded? :p

Yes - I'm not using the phrase, I just put plain text there.
(Which i'll update now)

Robbed 08-13-2006 02:12 AM

Kinda off topic, Is there a way to add a field in the postbit to show how many bans an admin has.

Maybe have an option to turn it on and off.

afterfl0w 08-13-2006 04:22 AM

Quote:

Originally Posted by Firestar.chkn
Hi,

I just installed this. I uploaded the files, made the changes to the bannings.php file, and imported the plugin.

I'm not sure though, if there are some instructions missing. I can see the options section, but I cannot see the ban/unban user section in the postbit.

Also, when I try to import the bans, I get an error message saying that I should be an admin to do it, and that I don't have permissions.

Running 3.6 gold.

Uh oh, forgot that template edit.

UPDATE COMING SOON!

Skaterscafe.com 08-13-2006 07:20 AM

Installed and tested, did a 10 min ban and it worked. I tried to run the import and got this:

Warning: Cannot use a scalar value as an array in /admincp/import_bans.php on line 127

Also have nothing in postbit, great hack!

afterfl0w 08-13-2006 11:04 PM

This is being updated, new version should be out within the next hour!

afterfl0w 08-14-2006 12:45 AM

New version released! Check first post for new additions and updated zip download!

EasyTarget 08-14-2006 09:12 PM

nice hack.

JWalker05 08-15-2006 11:28 PM

Ive been waiting for something like this. Awesome mod. *Installed and voted*

Firestar.chkn 08-15-2006 11:32 PM

Hi, is there any way to allow another usergroup besides Admin to see the banlist page?

I created a Core Admin Group on my forums, and they cannot see the page.

Regards
Firestar

Firestar.chkn 08-15-2006 11:42 PM

No matter, I found the way to do it. For those of you who wants to do the same, open the admincp/admin_banlist.php and find the following line of code on line 101:

Code:

if(!is_member_of($vbulletin->userinfo, 6)){
Replace this with:

Code:

if(!is_member_of($vbulletin->userinfo, 6) and !is_member_of($vbulletin->userinfo, 29)){
And just change the 26 into the usergroup that you want to give permission to. Obviously, you can add as many groups as possible, by just adding the code into that line, as I've done above.

cavyspirit 08-16-2006 02:28 AM

Any chance this could be made to work on other restricted user group statuses?

Now that we have the infraction system, I REALLY need a way to see my other restricted user groups as well.

afterfl0w 08-17-2006 03:10 PM

What do you mean?

cavyspirit 08-17-2006 04:41 PM

For example, we have two user groups that place posts on moderation. One allows for PMs, the other doesn't. We need to keep track of those just as much or more so than banned members.

It would be very, very nice if this reporting tied in with the new infraction system. Currently, nothing reports or lists infracted members and their user group status.

We're still forced to keep track manually in our mod forum of a summary of who is in the different groups.

redlabour 08-17-2006 05:10 PM

Excuse me - but what does this Hack do ? I think it is absolutely useless with the new Warning System in 3.6. There is allready a Timebased Banmodus at the Warning Features.

MThornback 08-22-2006 11:35 PM

Did the import bans script get pulled out of the zip? Cause its not in mine :(

b6gm6n 08-25-2006 03:26 PM

Hi dudes... looks and works well... but i wondered... i don't like seeing [ Ban User ] next to mods or admins names...is there a way i can disable that for certain user groups?...please advise, cheers

-b6

afterfl0w 08-27-2006 05:15 AM

Quote:

Originally Posted by redlabour
Excuse me - but what does this Hack do ? I think it is absolutely useless with the new Warning System in 3.6. There is allready a Timebased Banmodus at the Warning Features.

This is a permanent list of all banned users. No idea what you're comparing it to.

Quote:

Did the import bans script get pulled out of the zip? Cause its not in mine
It is now in the admin_banlist.php file. Upload it and surf to it and click on Import Bans :)

SportsZone 08-27-2006 08:08 AM

I have banned 2 members after in stalling the hack and they don't show in the banlist
http://www.sportszonefanatics.com/showbans.php

edit: I figured it out.

Is there any chance this hack could be coded so the last banned member shows up on the forum home page, please?

Also, when you edit the postbit template for the ban link, is it possible to somehow have the ban link appear in the profile drop downlink.

Great hack :)

b6gm6n 08-27-2006 05:59 PM

I like this mod... but i believe showing a [ ban user ] link for everyone shouldnt be the case... i think a drop down from a users profile upon clicking thier username would be much better and would tidy the postbits up a bit

-b6

EasyTarget 08-29-2006 03:55 PM

great mod/idea. I added it to the dropdown by editting the postbit and postbit legacy templates after the
HTML Code:

        <if condition="$post['userid'] AND $show['member']">
        <tr><td class="vbmenu_option"><a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$post[userid]"><phrase 1="$post[username]">$vbphrase[add_x_to_buddy_list]</phrase></a></td></tr>
        </if>

I added:
HTML Code:

<!-- afterflows banlist -->
<if condition="$bbusergroup[usergroupid]==6 OR can_moderate($forum[forumid], '', $bbuserinfo[userid])">
<if condition="$post[usergroupid]!=8">
 
<tr><td class="vbmenu_option"><a href="javascript:void(0);" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]&bannedpost=showthread.php?p=$post[postid]&postid=$post[postid]','ban','width=500,height=375,scrollbars=yes')">Ban User</a></td></tr>

</if> 
<if condition="$post[usergroupid]==8">

<tr><td class="vbmenu_option"><a href="javascript:void(0);" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','liftban','width=500,height=375,scrollbars=yes')">Unban User</a></td></tr>
 
</if>
</if>
        <!-- /end afterflows banlist -->

I'm guessing usergroup id 20 is a custom banned usergroup for afterflow?

I love how you can select which bans to have shown on the page but this bug occurred for me:
I was trying to remove a ban from the ban list in the admincp. I ticked the box for the most recent ban and then clicked delete bans. It then removed the oldest ban instead of the ban I was trying to remove.. each time I repeated it would do the same thing.

also, possible bug, but maybe its supposed to behave like this. I banned a user to test the banlist, it showed up find and the post was edited fine, however when I unbanned the user by clicking unban then the user still showed up on the banlist and the bantime was empty, just had ().

Suggestion:
make it so you can administer the bans from the showbans.php itself if you're in the appropriate usergroups.
make the admin pages match the admincp style.
add a section where you can edit the bans reason + link.
I like how you let us decide whether to edit the post or not, maybe as well you can let us choose the text/format which is added to the post.

SportsZone 08-29-2006 04:09 PM

EasyTarget: Awesome stuff! Thanks :)

Is there any chance this hack could be coded so the last banned member shows up on the forum home page, please?

b6gm6n 08-29-2006 06:30 PM

Nice one ET!

-b6

EasyTarget 08-30-2006 09:10 PM

I found there were a few bugs in that code still and I think this will fix it[html]
Code:

<!-- afterflows banlist -->
<if condition="$bbusergroup[usergroupid]==6 OR can_moderate($forum[forumid], '', $bbuserinfo[userid])">
<if condition="$post[usergroupid]!=8">
 
<tr><td class="vbmenu_option"><a href="javascript:void(0);" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]&bannedpost=showthread.php?p=$post[postid]&postid=$post[postid]','ban','width=500,height=375,scrollbars=yes')">Ban User</a></td></tr>

</if> 
<if condition="$post[usergroupid]==8">

<tr><td class="vbmenu_option"><a href="javascript:void(0);" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','liftban','width=500,height=375,scrollbars=yes')">Unban User</a></td></tr>
 
</if>
</if>
        <!-- /end afterflows banlist -->

Now when you ban a user and you click on their name in the postbit you'll see the unban option but not the ban one anymore.

SportsZone 08-30-2006 09:26 PM

So I am presuming we just remove the previous code you wrote and add this new code instead?

EasyTarget 08-30-2006 10:48 PM

yeah, I edited my previous post as well.

SportsZone 08-30-2006 11:10 PM

Awesome, thanks :)

EasyTarget 08-31-2006 11:22 PM

haha sorry guys, that code I posted still let everyone see the ban user option (of course they couldn't really ban a user, but they could still see the option). Got some help and this is verified to work.

This is the new code.. you only see ban/unban if you're an admin and you only see ban when a user isn't banned yet and only unban if they're already banned.

Code:

<!-- afterflows banlist -->
<if condition="$bbusergroup[usergroupid]==6 OR can_moderate($forum[forumid], '', $bbuserinfo[userid])">
 
<if condition="$post[usergroupid]!=8">
 
<tr><td class="vbmenu_option"><a href="javascript:void(0);" onClick="window.open('modcp/banning.php?do=banuser&userid=$post[userid]&bannedpost=showthread.php?p=$post[postid]&postid=$post[postid]','ban','width=500,height=375,scrollbars=yes')">Ban User</a></td></tr>

</if>
 
<if condition="$post[usergroupid]==8">

<tr><td class="vbmenu_option"><a href="javascript:void(0);" onClick="window.open('modcp/banning.php?do=liftban&userid=$post[userid]','liftban','width=500,height=375,scrollbars=yes')">Unban User</a></td></tr>
 
</if>

</if>
        <!-- /end afterflows banlist -->



All times are GMT. The time now is 02:20 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01302 seconds
  • Memory Usage 1,842KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_code_printable
  • (2)bbcode_html_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete