member_of

Summary

Fetches all roles which the user belongs to

Usage

fetch( 'user', 'member_of',
       hash( 'id', user_id ) )

Parameters

NameTypeDescriptionRequired
id integer The user ID to fetch roles from Yes.

Returns

An array with role objects

Description

This will return an array with role objects which are related to the user.

Examples

User is controlled by these roles:

{section var=role loop=fetch( 'user', 'member_of',

                             hash( 'id', 42 ) )}

{role.name}

{/section}

Comments

Contents

Reference

Database diagram
Template operators
Template functions
Data fetching
    Class
    Content
    Collaboration
    Layout
    Notification
    Package
    Section
    Shop
    URL
    User
       anonymous_count
       current_user
       is_logged_in
       logged_in_count
       logged_in_list
       logged_in_users
       member_of
       user_role
Modules
XML tags


Created

01/06/2004
6:27:14 pm
by Jan Borsodi

Last updated

14/06/2004
11:46:26 am
by Kåre Køhler Høvik

Authors

Jan Borsodi
Kåre Køhler Høvik



This page is part of the Exponential documentation. The documentation is available under the GNU Free Documentation License. All contributions will be released under the terms of this license.