vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   How do I do this? (https://vborg.vbsupport.ru/showthread.php?t=65386)

Mijae 05-22-2004 01:26 AM

How do I do this?
 
I have this code:

Code:

if ($bbuserinfo['usergroupid'] == '1' or $bbuserinfo['usergroupid'] == '3')
{
eval(print_standard_error('nopermission_gallery'));
}

And I want to add another line that will give a registered user with a VALIDATED account another error if his/her post count is below XX. How can I do this?

Mijae 05-22-2004 08:33 PM

Come on, how hard can it be for you people? :P

Majik? 05-22-2004 10:44 PM

If you want a different error to be displayed then just add this under that block of code:


PHP Code:

if ($bbuserinfo['usergroupid']!='1' AND $bbuserinfo['usergroupid']!='3' AND $bbuserinfo['usergroupid']!='4' AND $bbuserinfo['posts']<69)
{
// Some code or error message here.


Change the 69 to whatever number of posts.


If you want the same error message to be shown then change this:


PHP Code:

if ($bbuserinfo['usergroupid'] == '1' or $bbuserinfo['usergroupid'] == '3'

to this:


PHP Code:

if ($bbuserinfo['usergroupid']=='1' OR $bbuserinfo['usergroupid']=='3' OR ($bbuserinfo['usergroupid']!='4' AND $bbuserinfo['posts']<69)) 

But, if it were me.. I'd just use this (regardless of whether or not guests can post and I wanted the same error message):
PHP Code:

if ($bbuserinfo['usergroupid']=='1' OR $bbuserinfo['usergroupid']=='3' OR $bbuserinfo['usergroupid']=='4' OR $bbuserinfo['posts']<69


Mijae 05-23-2004 02:13 AM

Thanks! That'll annoy some people who sign up and dont post at my forums :D


All times are GMT. The time now is 09:59 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.00968 seconds
  • Memory Usage 1,724KB
  • 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
  • (4)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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