function answers_menu in Answers 5.2
Same name and namespace in other branches
- 6.2 answers.module \answers_menu()
- 6 answers.module \answers_menu()
- 7.4 answers.module \answers_menu()
- 7 answers.module \answers_menu()
- 7.2 answers.module \answers_menu()
- 7.3 answers.module \answers_menu()
Implementation of hook_menu().
File
- ./
answers.module, line 141 - Enables the creation of question nodes that can be answered by posting answer nodes.
Code
function answers_menu($may_cache) {
$items = array();
$nid = (int) arg(1);
global $user;
if ($may_cache) {
$items[] = array(
'path' => 'quest/list',
'callback' => 'answers_list',
'title' => t('Browse Quests'),
'access' => user_access('access content'),
'type' => MENU_CALLBACK,
);
}
$items[] = array(
'path' => 'admin/settings/answers',
'callback' => 'drupal_get_form',
'callback arguments' => array(
'answers_settings',
),
'title' => t('Answers settings'),
'description' => t('Configure Answers service settings'),
'access' => user_access('administer content types'),
'type' => MENU_NORMAL_ITEM,
);
return $items;
}