I'm stoked that Google Adsense is now built into Vbulletin but I'd like to limit the ads to certain usergroups. I know you need to modify the template but I'm not sure what conditions need to be added.
How to modify Google Adsense to show only to a specific group?
Collapse
X
-
This can be done with template conditionals. Here is the online documentation for using template conditionals:
vBulletin Conditionals Quick Tips:
vBulletin ConditionalsSteve Machol, former vBulletin Customer Support Manager (and NOT retired!)
Change CKEditor Colors to Match Style (for 4.1.4 and above)
Steve Machol Photography
Mankind is the only creature smart enough to know its own history, and dumb enough to ignore it.
-
is there a specific part of the template I'm supposed to put the condition? I'm in the ad part but I'm not sure where to put the new part.
Code:<if condition="in_array($bbuserinfo[userid], array(1,2,9,13))"></if>
Comment
-
I don't have the new adsense options enabled because I've always used adsense on my forum using the ad_location_templates.
Wrap the conditional around the adsense code.
Code:<if condition="is_member_of($bbuserinfo,1,2,9,13)"> <!-- adsense code here --> </if>
Comment
-
Search and ye will find
I found this a few days ago while surfing.
Comment
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Comment