Adding a permission

Jake B.

Well-known member
#4
Admin -> Development -> Permissions -> Permission Definitions

You can create all the permissions you want here, they just won't do anything
 

Steve F

Well-known member
#6
You can sort of cheat and use the syntax below for permissions. Assuming you are wanting to restrict the view of something, or however you want to configure it. ufk prefix is just so its unique as the id's have to be.

Admin -> Development -> Permissions -> Permission Definitions -> New Permission Group
  1. Permission Group ID: ufkGeneral
  2. Title: UFK Permissions
  3. Add-on: (Not needed)

Admin -> Development -> Permissions -> Permission Definitions -> New Interface Group
  1. Interface Group ID: ukfGeneralPermissions
  2. Title: UFK General Permissions
  3. Add-on: (Not Need)
Admin -> Development -> Permissions -> Permission Definitions -> New Permission
  1. Permission ID: canViewStuff
  2. Title: Can view stuff
  3. Permission Group: ufkGeneral
  4. Depends on Permission ID: (Can leave blank)
  5. Permission Type: Flag
  6. Interface Group ID: ukfGeneralPermissions
  7. Add-on: (Not needed)


Then you can use this syntax in a template:
Code:
<xen:if is="{$visitor.permissions.ukfGeneralPermissions.canViewStuff}">
Some code stuff...
</xen:if>

Good luck!
 

Steve F

Well-known member
#8
I guess we would need to know what you're trying to do?

The permission example I posted is a flag, basically can or can't see or do what is inside the code example.
 
Top