Go to page content

m_acl

Basic access control information.

The m_acl model gives access to basic access control information about the current user.

The following m_acl model properties are available in templates:

PropertyDescriptionExample value
userThe id of the currently logged on user. Returns the atom undefined when no user is logged on.1

is_admin

Check if the current user is an administrator. Returns a bool.false
is_supervisorCheck if the current user is a supervisor. Returns a bool.true
is_community_publisherCheck if the current user has rights to publish content for the community.true
is_public_publisherCheck if the current user has rights to publish content for the world.false
observerThe list of groups for which the current user is observer.[300]
memberThe list of groups of which the current user is member.[309,578]
leaderThe list of groups of which the current user is leader.[578]

This page is part of the Zotonic documentation, which is licensed under the Apache License 2.0.