function poll_menu
7.x poll.module | poll_menu() |
6.x poll.module | poll_menu() |
Implements hook_menu().
File
- drupal-7.x/
modules/ poll/ poll.module, line 89 - Enables your site to capture votes on different topics in the form of multiple choice questions.
Code
function poll_menu() {
$items['poll'] = array(
'title' => 'Polls',
'page callback' => 'poll_page',
'access arguments' => array('access content'),
'type' => MENU_SUGGESTED_ITEM,
'file' => 'poll.pages.inc',
);
$items['node/%node/votes'] = array(
'title' => 'Votes',
'page callback' => 'poll_votes',
'page arguments' => array(1),
'access callback' => '_poll_menu_access',
'access arguments' => array(1, 'inspect all votes', FALSE),
'weight' => 3,
'type' => MENU_LOCAL_TASK,
'file' => 'poll.pages.inc',
);
$items['node/%node/results'] = array(
'title' => 'Results',
'page callback' => 'poll_results',
'page arguments' => array(1),
'access callback' => '_poll_menu_access',
'access arguments' => array(1, 'access content', TRUE),
'weight' => 3,
'type' => MENU_LOCAL_TASK,
'file' => 'poll.pages.inc',
);
return $items;
}