vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   if conditional help (https://vborg.vbsupport.ru/showthread.php?t=215250)

tipoboy 06-03-2009 11:47 AM

if conditional help
 
tried a search but i cant find anything to help me, i'm probably not inputing the correct criteria but hey, should be an easy one

looking for and if condition that specifys show a link if only members 1 and 2

so would look something like

<if condition="memberid =1" OR "memberid=2">link to show</if>

hope you all follow

TIA

dave
:D

Spank 06-03-2009 12:09 PM

I think it would be:

Code:

<if condition="$bbuserinfo['userid'] == 1"> link to show</if>
Give that a try anyway.

tipoboy 06-03-2009 12:12 PM

Quote:

Originally Posted by Spank (Post 1822696)
I think it would be:

Code:

<if condition="$bbuserinfo['userid'] == 1"> link to show</if>
Give that a try anyway.

kool thanks for the quick reply but i want the link only to show for 2 members onl so would it be something like:

Code:

<if condition="$bbuserinfo['userid'] ==1 AND 2">
or would i have to use a double barrleed conditional like:

Code:

<if condition="$bbuserinfo['userid'] == 1">
<if condition="$bbuserinfo['userid'] == 2">
link to show
</if>
</if>

Thanks again

Spank 06-03-2009 12:16 PM

Ah I see. I'm not too sure on this, but I think if you did it like this it would work:

Code:

<if condition="$bbuserinfo['userid'] == 1,2"> link to show</if>

tipoboy 06-03-2009 12:17 PM

Thanks spank i'll give it a shot

:D

EnIgMa1234 06-03-2009 01:06 PM

Quote:

Originally Posted by tipoboy (Post 1822702)
Thanks spank i'll give it a shot

:D

Try this:

Code:

<if condition="$bbuserinfo[userid] == 1 OR $bbuserinfo[userid] == 2">
// YOUR CODE
</if>


tipoboy 06-03-2009 01:12 PM

Quote:

Originally Posted by EnIgMa1234 (Post 1822716)
Try this:

Code:

<if condition="$bbuserinfo[userid] == 1 OR $bbuserinfo[userid] == 2">
// YOUR CODE
</if>


That worked Enigma thanks very much :)

Thanks again Spank for the quick replies :D


All times are GMT. The time now is 11:47 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.01120 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
  • (7)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)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