PDA

View Full Version : Forum If Condition How?


Colicab2
02-09-2004, 08:19 PM
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
<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:

<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.


<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


<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
I use this for the nav bar


<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?