![]() |
if condition forumdisplay only
I show adsense on all pages by putting the code at the bottom of the navbit template.
I want to exclude showing adsense on forums 23 and 24 on the forumdisplay page ONLY. I still want the ads to show on the showthread pages for forums 23 and 24. I tried the below code but it excluded the ads not only on forums 23 and 24 forumdisplay page but all showthread pages for forums 23 and 24. Code:
<if condition="!in_array($foruminfo['forumid'], array(23,24)) AND THIS_SCRIPT != 'forumdisplay'"> |
I think you just want OR instead of AND.
|
kh99 thank you so much!
I don't know why I didn't try OR, it just didn't seem to make sense, but it works! |
Yeah, it's kind of backwards to think about the conditions where it *would* display instead of where you don't want it. You could also use:
Code:
<if condition="!(in_array($foruminfo['forumid'], array(23,24)) AND THIS_SCRIPT == 'forumdisplay')"> since !(A AND B) = !A OR !B. |
I don't understand why it works, but it does, thanks again!
|
All times are GMT. The time now is 12:22 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|