Announcement

Collapse
No announcement yet.

UserId with Adsense below Navbar

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • UserId with Adsense below Navbar

    I'm trying to have adsense display between my header and my navbar, and display being conditional on the UserId. Currently I have one adsense bar displayed to user Id's 1,3,4,8, and 16. Can someone please point me where I can find the snippet of code I need to insert in order to do this?

    Thanks

  • #2
    Try this at the end of the header template:
    Code:
    <if condition="is_member_of($bbuserinfo,1,3,4,8,16)">
    
    	adsense and related stuff here
    
    </if>

    Comment


    • #3
      Thanks calorie, actually in thinking more about this, I'm wondering if adsense will display anything relevant to the content of my forum. My logic is that the adsense code will only key off of the page its on, thus I'll wind up with nothing that remotely matches the content of my forum. Does anyone have any opinion on this?

      Comment


      • #4
        Originally posted by calorie View Post
        Try this at the end of the header template:
        Code:
        <if condition="is_member_of($bbuserinfo,1,3,4,8,16)">
        
            adsense and related stuff here
        
        </if>
        that's for usergroupID's, I believe dssart asked for userID:

        Code:
        <if condition="in_array($bbuserinfo['userid'], array(1,3,4,8,16))">
            adsense and related stuff here
        </if>

        Comment


        • #5
          @Luggruff: yep, dssart wrote userid, but it seems like a typo. Why show ads to five users?

          @dssart: you might find this page useful.

          Comment

          widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
          Working...
          X