function linkchecker_menu in Link checker 5.2
Same name and namespace in other branches
- 5 linkchecker.module \linkchecker_menu()
- 6.2 linkchecker.module \linkchecker_menu()
- 7 linkchecker.module \linkchecker_menu()
Implementation of hook_menu().
File
- ./
linkchecker.module, line 83 - This module periodically check links in given node types, blocks, cck fields, etc.
Code
function linkchecker_menu($may_cache) {
$items = array();
if ($may_cache) {
$items[] = array(
'path' => 'admin/settings/linkchecker',
'title' => t('Link checker'),
'description' => t('Configure the link checker settings.'),
'callback' => 'drupal_get_form',
'callback arguments' => array(
'linkchecker_admin_settings_form',
),
'access' => user_access('administer linkchecker'),
);
$items[] = array(
'path' => 'admin/logs/linkchecker',
'title' => t('Broken links'),
'description' => t('Shows a list of broken links in content.'),
'callback' => 'linkchecker_admin_report',
'access' => user_access('access broken links report'),
);
}
else {
$items[] = array(
'path' => 'linkchecker/' . arg(1) . '/edit',
'title' => t('Edit link settings'),
'callback' => 'drupal_get_form',
'callback arguments' => array(
'linkchecker_link_edit_form',
arg(1),
),
'access' => user_access('edit link settings'),
'type' => MENU_CALLBACK,
);
}
return $items;
}