Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
banning options for smods Details »»
banning options for smods
Version: 1.01, by Carnage Carnage is offline
Developer Last Online: Sep 2014 Show Printable Version Email this Page

Version: 3.0.3 Rating:
Released: 01-23-2005 Last Update: 01-23-2005 Installs: 5
 
No support by the author.

this has been requested, and i've throw something together by editing options.php and making a new file with it, it only allows access to the banning options. It will also give admins access to the banning options even if they don't have vboptions access permissions so this may be useful for meny people.

i'd recormend applying this hack: https://vborg.vbsupport.ru/showthread.php?t=64034 as well to prevent smods ip banning superadmins and other privilaged users.

to check if a user id an smod, i used the can_moderate function to check the permission 'issmod' as this dosn't exist as a permission it will only return true if the user is a smod or admin if you want to allow mods to ipban you can add this permission and give it to them.

Instalation, copy ipban.php to your modcp directory.

As this is a beta i've not yet added it to any menus within the mod or admin cp if you want to do this you'll have to do it yourself until i get arround to doing more work on this.

Totally re-written addressing first few posts... lesson learn: a 'quick solution' isn't the best solution....

As always backup database and forum files before installing.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 01-25-2005, 02:18 PM
Carnage Carnage is offline
 
Join Date: Jan 2005
Location: uk
Posts: 760
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by dbembibre
If you want make a link in you mod control panel only need make this.

Open modcp/index.php

Search:
Code:
if (can_moderate(0, 'canbanusers'))
	{
		$canuser = true;
		construct_nav_option($vbphrase['ban_user'], 'banning.php?do=banuser', '<br />');
Add:
Code:
construct_nav_option('Ban IP/Mail', 'ipban.php', '<br />');
Or create a new vbphrase and replace with this

Code:
construct_nav_option($vbphrase['banIP'], 'ipban.php', '<br />');
Excuse my broken English

basically, yes that will add a link, but access to this is controled by a none existant permission (so its not possible to give it to mods) thus only smods+ can have access. You have added it to the cp using the banusers permission which mods can have. dosn't matter too much since they will just get a permission error on the ipban page.

now to explain this a little better:

Code:
construct_nav_option('Ban IP/Mail', 'ipban.php', '<br />');
^ that one will work fine if you add it under:

Code:
construct_nav_option($vbphrase['ban_user'], 'banning.php?do=banuser', '<br />');
however if you add a vb phrase 'banIP' you can add the line below INSTEAD of the first line to use the phrase instead, its all a matter of personal preferance.

Code:
construct_nav_option($vbphrase['banIP'], 'ipban.php', '<br />');
Reply With Quote
  #13  
Old 09-12-2006, 06:29 PM
Zelos's Avatar
Zelos Zelos is offline
 
Join Date: Jun 2006
Posts: 80
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Any chance this will be ported to 3.6? I could seriously use this!
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 06:47 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07283 seconds
  • Memory Usage 2,215KB
  • Queries Executed 17 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (6)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (3)post_thanks_box
  • (3)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (3)post_thanks_postbit_info
  • (2)postbit
  • (3)postbit_onlinestatus
  • (3)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete