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

XF 1.4 Hide extra user info for staff only

Discussion in 'Styling and Customization Questions' started by Newt, Jan 22, 2015.

  1. Newt

    Newt Active Member

    How do I...?
  2. Brogan

    Brogan XenForo Moderator Staff Member

    You would need to edit the template and wrap the content in a conditional statement.
    Newt likes this.
  3. Adam K M

    Adam K M Active Member

    @Newt, the conditional you would need is:
    <xen:if is="{$visitor.is_admin} OR {$visitor.is_moderator}">
    This content will show to Administrators and Moderators
    This was taken straight from this great resource.
    Newt likes this.
  4. Newt

    Newt Active Member

    Yup, awesome thanks!
    Adam K M likes this.
  5. Brogan

    Brogan XenForo Moderator Staff Member

    You could also use $visitor.is_staff.
  6. Newt

    Newt Active Member

    Does this code work for any staff member or only those in the staff usergroup and not the admins or moderators?

    Oh and can I remove the staff's user info for everyone? I think it would be something in extra.css since there is no conditional involved?
  7. Brogan

    Brogan XenForo Moderator Staff Member

    It's not user group related, it's related to this setting:


    If that is unchecked, is_staff will be false.

Share This Page