• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Conditionals not working for specific usergroup

Ingenious

Well-known member
#1
I have added an additional "Staff online" sidebar, but called "Sponsors online" which I only want to list members online who are in usergroup 6.

I am using this code:

Code:
<!-- block: sidebar_online_sponsors -->
<xen:if hascontent="true">
    <div class="section staffOnline avatarList">
        <div class="secondaryContent">
            <h3>Sponsors Online Now</h3>
            <ul>
                <xen:contentcheck>
                    <xen:foreach loop="$onlineUsers.records" value="$user">
                        <xen:if is="{xen:helper ismemberof, $visitor, 6}">
                            <li>
                                <xen:avatar user="$user" size="s" img="true" />
                                <xen:username user="$user" rich="true" />
                                <div class="userTitle">{xen:helper userTitle, $user}</div>
                            </li>
                        </xen:if>
                    </xen:foreach>
                </xen:contentcheck>
            </ul>
        </div>
    </div>
</xen:if>
<!-- end block: sidebar_online_sponsors -->
But ALL on-line members are showing there, even if they are not members of usergroup 6.

What have I done wrong here please?