XF 1.1 Display adverts/text for guests only


Well-known member
I want to have the adverts on my website show to guests only. What code do I need to enter above and below my google adsense code please?


Well-known member
A quick follow up: If I only want to show the ads to visitor and also "regular" members, but not to paid members, how would the code be edited? For example:

Show ads only to visitor and members, but not to "premium members"

Sorry to bump an old thread but it's relevant. Reference:

<xen:if is="!{xen:helper ismemberof, $visitor, x}">
This content will be hidden from members of user group x
How do I go about editing this so the content can be hidden from several usergroups. Specifically - Admins/Mods/Paid users.

Also how do I identify the code for each usergroup. IE visitors = $visitor

Many thanks for any assistance,


XenForo moderator
Staff member
The link in my post above explains how to create a conditional statement for multiple user groups.

The ID for each user group can be seen by clicking on the user group in the ACP and looking at the browser address bar.