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

XF 1.4 staff online now

Discussion in 'XenForo Questions and Support' started by aussie, Jul 3, 2015.

  1. aussie

    aussie Member

    Is there anyway to show just "staff online now" without "members online now" on the sidebar?

    cheers
     
  2. Sami Jalal

    Sami Jalal Well-Known Member

  3. Sami Jalal

    Sami Jalal Well-Known Member

  4. Amaury

    Amaury Well-Known Member

    Template: sidebar_online_users

    Find:

    Code:
    <div class="section membersOnline userList">       
        <div class="secondaryContent">
            <h3><a href="{xen:link online}" title="{xen:phrase see_all_online_users}">{xen:phrase members_online_now}</a></h3>
           
            <xen:if is="{$onlineUsers.records}">
           
                <xen:if is="{$visitor.user_id}">
                    <xen:if hascontent="true">
                    <h4 class="minorHeading"><a href="{xen:link account/following}">{xen:phrase people_you_follow}:</a></h4>
                    <ul class="followedOnline">
                        <xen:contentcheck>
                            <xen:foreach loop="$onlineUsers.records" value="$user">
                                <xen:if is="{$user.followed}">
                                    <li title="{$user.username}" class="Tooltip"><xen:avatar user="$user" size="s" img="true" class="_plainImage" /></li>
                                </xen:if>
                            </xen:foreach>
                        </xen:contentcheck>
                    </ul>
                    <h4 class="minorHeading"><a href="{xen:link members}">{xen:phrase members}:</a></h4>
                    </xen:if>
                </xen:if>
               
                <ol class="listInline">
                    <xen:foreach loop="$onlineUsers.records" value="$user" i="$i">
                        <xen:if is="{$i} <= {$onlineUsers.limit}">
                            <li>
                            <xen:if is="{$user.user_id}">
                                <a href="{xen:link members, $user}"
                                    class="username{xen:if '!{$user.visible}', ' invisible'}{xen:if {$user.followed}, ' followed'}">{$user.username}</a><xen:if is="{$i} < {$onlineUsers.limit}">,</xen:if>
                            <xen:else />
                                {xen:phrase guest}<xen:if is="{$i} < {$onlineUsers.limit}">,</xen:if>
                            </xen:if>
                            </li>
                        </xen:if>
                    </xen:foreach>
                    <xen:if is="{$onlineUsers.recordsUnseen}">
                        <li class="moreLink">... <a href="{xen:link online}" title="{xen:phrase see_all_visitors}">{xen:phrase and_x_more, 'count={xen:number $onlineUsers.recordsUnseen}'}</a></li>
                    </xen:if>
                </ol>
            </xen:if>
           
            <div class="footnote">
                {xen:phrase online_now_x_members_y_guests_z_robots_a, 'total={xen:number $onlineUsers.total}', 'members={xen:number $onlineUsers.members}', 'guests={xen:number $onlineUsers.guests}', 'robots={xen:number $onlineUsers.robots}'}
            </div>
        </div>
    </div>
    And wrap it in <xen:comment></xen:comment>.
     
    C.Stanley likes this.
  5. aussie

    aussie Member

    thank you! I went with Amaury's advice and it worked perfect.:)

    cheers
     
    Amaury likes this.
  6. jamalfree

    jamalfree Active Member

    an other idea
    template
    sidebar_visitor_panel
    in the end template before

    <xen:include template="ad_sidebar_below_visitor_panel" />
    put this
    Code:
    <xen:if is="!{$visitor.is_admin}">
    <style> .membersOnline {display:none} </style>
    </xen:if>
    only admin can show membersOnline you can specify groups..
     
  7. Amaury

    Amaury Well-Known Member

    @jamalfree, that's not what he asked, though. He just wanted to hide it completely.
     
  8. jamalfree

    jamalfree Active Member

    simply
    extra.css
    .membersOnline {display:none}
     
  9. Amaury

    Amaury Well-Known Member

Share This Page