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

hasPermissions in templates?

Discussion in 'XenForo Development Discussions' started by Nasr, Mar 20, 2011.

  1. Nasr

    Nasr Well-Known Member

    Is it possible to use "hasPermissions" as a conditional in templates?
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Do you mean with regards to a specific permission?

    There isn't anything like that but there are things such as $post.canInlineMod, $post.canEdit, $post.canDelete, etc.
     
  3. Nasr

    Nasr Well-Known Member

    What I meant is, let say a mod has the ability to ban a member, instead of using $isAdmin or isMod rather, can we use something like $hasPermissions= 'permission'

    Something of that nature?
     
  4. Brogan

    Brogan XenForo Moderator Staff Member

    You can't do that as far as I am aware as banning is only available from the ACP.

    You could use this though: <xen:if is="{$post.canCleanSpam}">
     

Share This Page