Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 21 Jan 2011, 20:39
treasureman treasureman is offline
 
Join Date: Feb 2006
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.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Any help is appreciated.
Reply With Quote
  #2  
Old 21 Jan 2011, 21:31
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
I think you just want OR instead of AND.
Reply With Quote
  #3  
Old 21 Jan 2011, 21:51
treasureman treasureman is offline
 
Join Date: Feb 2006
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!
Reply With Quote
  #4  
Old 21 Jan 2011, 22:27
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
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:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


since !(A AND B) = !A OR !B.
Reply With Quote
  #5  
Old 22 Jan 2011, 00:29
treasureman treasureman is offline
 
Join Date: Feb 2006
I don't understand why it works, but it does, thanks again!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 10:11.

Layout Options | Width: Wide Color: