You are here

function vud_menu in Vote Up/Down 6.2

Same name and namespace in other branches
  1. 6.3 vud.module \vud_menu()
  2. 7.2 vud.module \vud_menu()
  3. 7 vud.module \vud_menu()

Implementation of hook_menu().

File

./vud.module, line 58

Code

function vud_menu() {
  $items = array();
  $items['admin/settings/voteupdown'] = array(
    'title' => 'Vote Up/Down',
    'description' => 'Control the functioning of Vote Up/Down.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'vud_admin_advanced_settings',
    ),
    'access arguments' => array(
      'administer vote up/down',
    ),
    'type' => MENU_NORMAL_ITEM,
  );
  $items['admin/settings/voteupdown/advanced'] = array(
    'title' => 'General',
    'type' => MENU_DEFAULT_LOCAL_TASK,
    'weight' => -10,
  );
  $items['vote/%/%/%/%/%/%'] = array(
    'title' => 'Vote',
    'page callback' => 'vud_vote',
    'page arguments' => array(
      1,
      2,
      3,
      4,
      5,
      6,
    ),
    'access arguments' => array(
      'use vote up/down',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'vud.theme.inc',
  );
  $items['votereset/%/%/%/%'] = array(
    'title' => 'Reset vote',
    'page callback' => 'vud_reset',
    'page arguments' => array(
      1,
      2,
      3,
      4,
    ),
    'access arguments' => array(
      'reset vote up/down votes',
    ),
    'type' => MENU_CALLBACK,
  );
  $items['user/%user/vote_up_down/votes'] = array(
    'title' => 'Votes',
    'page callback' => 'vud_user_votes',
    'page arguments' => array(
      1,
    ),
    'access callback' => 'vud_can_see_votes',
    'access arguments' => array(
      1,
    ),
    'type' => MENU_LOCAL_TASK,
  );
  $items['vud/%ctools_js/denied/%'] = array(
    'title' => 'Vote denied',
    'page callback' => 'vud_denied_vote',
    'page arguments' => array(
      1,
      3,
    ),
    'access arguments' => array(
      'access content',
    ),
    'type' => MENU_CALLBACK,
  );
  return $items;
}