vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Forum If Condition How? (https://vborg.vbsupport.ru/showthread.php?t=88435)

Colicab2 02-09-2004 08:19 PM

Forum If Condition How?
 
How would i create a piece of html that would show only in 2 forums (ids) that would show a message? im no good at the conditionals.. is theer a list of them etc?

assassingod 02-09-2004 08:33 PM

Code:

<if condition="in_array($forum['forumid'], array(X,Y))">
text here
<else />
other text
</if>

Should work, replace X and Y with the appropriate IDs:)

assassingod 02-09-2004 09:45 PM

Use this instead:
Code:

<if condition="in_array($foruminfo['forumid'], array(X,Y))">
It works!
</if>

replace X and Y with the appropriate IDs

RickFla 04-27-2004 04:27 PM

Can this be used to restrict certain user groups from seeing a link on the navbar by using $bbuserinfo['membergroupids']? If so, how? The code I tried did not work.

Code:

<if condition="in_array($bbuserinfo['membergroupids'], array('5,6,7,10')">
<td class="vbmenu_control"><a href="../maillogin.html">WebMail</a>
</if>


RickFla 04-28-2004 12:45 PM

Can anyone help on this?

milkmycow 04-28-2004 04:48 PM

i would think that would work.. why not just try it?

Jolten 04-29-2004 01:28 AM

I use this for the nav bar

Code:

<if condition="!$show['guest']">Link info here </if>
replace guest with the appropriate user group title. It will hide the link from the usergroup(s) named in the if statement.

RickFla 04-29-2004 02:52 PM

Quote:

Originally Posted by ScottW
I use this for the nav bar

Code:

<if condition="!$show['guest']">Link info here </if>
replace guest with the appropriate user group title. It will hide the link from the usergroup(s) named in the if statement.


Can you comma seperate the usergroups if you have more than one?


All times are GMT. The time now is 11:09 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.01196 seconds
  • Memory Usage 1,725KB
  • 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
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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