The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
VB Condition to show Ads in certain forums only
I'm trying to disable ads in certain forum sections, I tried this
<vb:if condition="$forum[forumid] != 42"> ad code </vb:if> where 42 is the forum section I don't want ads to show, this doesn't seem to work. anyone know why? |
#2
|
|||
|
|||
$forum[forumid] might not be the right variable to check. It depends on what template you're putting the code in - assuming you are putting it in a template. [S]If you're putting it in the ad html, that's probably why it isn't working.[/S] Edit: that's wrong - you *can* put conditionals in the ad code.
|
#3
|
|||
|
|||
I've tried putting it in several templates some that were created by mod and default templates.
SHOWTHREAD ad_global_above_footer postbit_legacy_ads_after_firstpost I tried all the same condition in all three templates and it doesn't seem to work. What other variables could I use to get this to work? Thanks! |
#4
|
|||
|
|||
Actually I just noticed this in the "Similar Threads" below: https://vborg.vbsupport.ru/showthread.php?t=250513
So that might help you. It also seems to say that you *can* put it in the ad code, so maybe I'm wrong about that (I'll check the code when I get a chance). Edit: no need to check the code, it says right on the ad editing page that conditionals *are* allowed. So, try the one at the link above. |
#5
|
|||
|
|||
thanks kh99, worked
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|