function user_permission

Implements hook_permission().

File

modules/user/user.module, line 881

Code

function user_permission() {
    return array(
        'administer permissions' => array(
            'title' => t('Administer permissions'),
            'restrict access' => TRUE,
        ),
        'administer users' => array(
            'title' => t('Administer users'),
            'restrict access' => TRUE,
        ),
        'access user profiles' => array(
            'title' => t('View user profiles'),
        ),
        'change own username' => array(
            'title' => t('Change own username'),
        ),
        'cancel account' => array(
            'title' => t('Cancel own user account'),
            'description' => t('Note: content may be kept, unpublished, deleted or transferred to the %anonymous-name user depending on the configured <a href="@user-settings-url">user settings</a>.', array(
                '%anonymous-name' => variable_get('anonymous', t('Anonymous')),
                '@user-settings-url' => url('admin/config/people/accounts'),
            )),
        ),
        'select account cancellation method' => array(
            'title' => t('Select method for cancelling own account'),
            'restrict access' => TRUE,
        ),
    );
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.