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

XF 1.4 A condition if the user has a banner (only in threads and conversations)?

Discussion in 'XenForo Questions and Support' started by Dylan V, Feb 15, 2015.

  1. Dylan V

    Dylan V Well-Known Member

    Hello,

    I'd like to know if it was possible to display different content if the user has a banner in the threads and conversations. If yes, can you give me the condition?

    Thanks.
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Presumably the banner is applied via a user group?

    If so, you can use a standard user group ID check.
     
  3. Dylan V

    Dylan V Well-Known Member

    I have a problem, Brogan. Look at the picture:

    7yawsyu.png

    I'd like to put an option allowing, if the user has no banner, so I can adjust the height where the arrow indicates the element. Basically, use something like this:

    Code:
    <xen:if is="{$xenOptions.userBanners}">
    
    <xen:else />
    
    .messageUserBlock .extraUserInfo
    {
        margin-top: -50px;
    }
    
    </xen:if>
    But I can't find the condition to do that only if the user does not have any banner.
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    As above - banners are applied via user groups or for staff members, so you can use a user group conditional check.
     
  5. Dylan V

    Dylan V Well-Known Member

    Can you give me an example please?
     
  6. Brogan

    Brogan XenForo Moderator Staff Member

Share This Page