vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=252)
-   -   Flood control usergroups/single member? (https://vborg.vbsupport.ru/showthread.php?t=241357)

movslow 04-27-2010 11:57 AM

Flood control usergroups/single member?
 
I've noticed that w/vb4 administrators don't have the option to flood control individual members.

You can set a time in seconds for the entire forum, but not certain groups/members.

Would it be difficult for a mod to be written than would encompass just a single user and/or group?

I believe it would come in VERY handy.

Thank you in advance
:up:

movslow 04-30-2010 04:02 PM

Anyone?

movslow 05-03-2010 01:08 PM

Hewo?

Lynne 05-03-2010 02:01 PM

Just write a plugin to do it.
global_start
PHP Code:

if (in_array($vbulletin->userinfo['userid'], array(xyz)))
{
$vbulletin->options['floodchecktime']=aa;



movslow 05-05-2010 06:52 PM

Quote:

Originally Posted by Lynne (Post 2031124)
Just write a plugin to do it.
global_start
PHP Code:

if (in_array($vbulletin->userinfo['userid'], array(xyz)))
{
$vbulletin->options['floodchecktime']=aa;



I've never written a plugin?
:confused:

Lynne 05-05-2010 08:36 PM

There's a first time for everything. :)

Plugin System

movslow 06-23-2010 04:32 PM

Quote:

Originally Posted by Lynne (Post 2032304)
There's a first time for everything. :)

Plugin System

I'll check that out, thank you.

DaVitsche 10-12-2011 01:46 PM

I am encountering a similar problem. I need to set a timelimit between posts for single users .
I really can't write a plugin, as in really no idea what and how.
If someone wrote this and is willing to share it, that would be great.

kh99 10-12-2011 02:33 PM

Quote:

Originally Posted by DaVitsche (Post 2256291)
I am encountering a similar problem. I need to set a timelimit between posts for single users .
I really can't write a plugin, as in really no idea what and how.
If someone wrote this and is willing to share it, that would be great.

You could do this: follow the instructions for creating a plugin here: https://www.vbulletin.com/docs/html/plugin_system (same link as is posted above). It's pretty easy, and if you don't understand what an option does you can probably leave the default value, or else ask here.

Anyway, use hook location global_bootstrap_init_start and this code:

Code:

if (in_array($vbulletin->userinfo['userid'], array(A, B, C)))
    $vbulletin->options['floodchecktime'] = X;


You'll need to change the parts in red - A, B, C to one or more userids, and X to the new flood check time in seconds. If you want to set different times for different users you can repeat that code as many times as you need with different userid and times.

DaVitsche 10-13-2011 04:22 AM

thank you so much!


All times are GMT. The time now is 05:04 AM.

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.01097 seconds
  • Memory Usage 1,736KB
  • 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
  • (1)bbcode_code_printable
  • (2)bbcode_php_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete