You are here

function nodeaccess_menu in Nodeaccess 7

Same name and namespace in other branches
  1. 5 nodeaccess.module \nodeaccess_menu()
  2. 6.2 nodeaccess.module \nodeaccess_menu()
  3. 6 nodeaccess.module \nodeaccess_menu()

Implements hook_menu().

Return value

array

File

./nodeaccess.module, line 33
Provide per node access control

Code

function nodeaccess_menu() {
  $items = array();
  $items['admin/config/people/nodeaccess'] = array(
    'title' => 'Nodeaccess',
    'description' => 'Change default settings for the Nodeaccess module.',
    'page callback' => 'nodeaccess_admin',
    'file' => 'nodeaccess.admin.inc',
    'access arguments' => array(
      'administer nodeaccess',
    ),
  );
  $items['node/%node/grant'] = array(
    'title' => 'Grant',
    'page callback' => 'nodeaccess_grant_tab',
    'page arguments' => array(
      1,
    ),
    'access callback' => 'nodeaccess_access',
    'access arguments' => array(
      'grant',
      1,
    ),
    'weight' => 5,
    'type' => MENU_LOCAL_TASK,
  );
  return $items;
}