The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Conditional help needed for postbit
I'm adding something to the postbit templates for our discussion board. Here's what I'm after: if the specific forum is visible to the public, whether or not a user is logged in, I want the item (an icon in an <img> tag) to display in the postbit. If it is a non-public forum, then I do not want anything to display. Also, I noticed that this item also shows up in the postbit for private messaging, which we also don't want.
I had thought of doing a conditional like this: Code:
<if condition="$forum[forumid] == 28"> I cannot base it on usergroup, since the item will need to appear whether or not a user is logged in. Is there a conditional I can use that would accomplish what I'm looking for? Hopefully I have described it well enough. I did create a conditional for iTrader, so that it shows up only in our Classifieds forum (which is where I grabbed my conditional sample from, above). I also have a custom navigation system that changes whether or not a user is logged in, but the code I need cannot be based on the customer's logged-in status. --------------- Added [DATE]1315088619[/DATE] at [TIME]1315088619[/TIME] --------------- This might work: Code:
<if condition="in_array($forum['forumid'], array(1,2,3,6))"></if> And, would this prevent it displaying in the private message postbit as well? |
#2
|
||||
|
||||
I don't know if there is a condition regarding whether a forum is private or not. Perhaps someone else knows.
But, the condition for whether it shows in private messages would be: HTML Code:
<if condition="THIS_SCRIPT != 'private'"> stuff to not show in private message postbit </if> |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|