You are here

function path_access_admin_roles in Path Access 7

Same name and namespace in other branches
  1. 6 path_access.module \path_access_admin_roles()

Menu callback; displays the path access configuration form.

1 string reference to 'path_access_admin_roles'
path_access_menu in ./path_access.module
Implements hook_menu().

File

./path_access.module, line 124
Restricts access to any Drupal path on a per-role basis.

Code

function path_access_admin_roles() {

  // Render the role overview.
  $result = db_query('SELECT * FROM {role} ORDER BY name');
  $table['header'] = array(
    t('User Role'),
    t('Operations'),
  );
  foreach ($result as $role) {
    $table['rows'][] = array(
      $role->name,
      l(t('edit'), 'admin/config/people/pathaccess/edit/' . $role->rid),
    );
  }
  $output = theme('table', $table);
  return $output;
}