function revisioning_ux_menu_alter in Revisioning 7
Same name and namespace in other branches
- 8 revisioning_ux/revisioning_ux.module \revisioning_ux_menu_alter()
Implements hook_menu_alter().
Use a consistent title, 'Revision operations' for the revisions tab. Insure that the sub-tabs shown on the various Revisioning Operations pages remain consistent.
File
- revisioning_ux/
revisioning_ux.module, line 95 - Revisioning User Experience Adjustments
Code
function revisioning_ux_menu_alter(&$items) {
// Put back the standard access callback (remove revisioning callback that
// hides 'View' and 'Edit').
$items['node/%node']['access callback'] = 'node_access';
$items['node/%node/revisions']['page arguments'] = array(
1,
$items['node/%node/revisions']['page callback'],
);
$items['node/%node/revisions']['page callback'] = '_revisioning_ux_revisioning_redirect';
$items['node/%node/revisions']['title callback'] = '_revisioning_ux_revisioning_title_for_tab';
unset($items['node/%node/revisions/list']);
$items['node/%node/revisions/%vid/view']['title callback'] = '_revisioning_ux_revisioning_title_for_edit_and_view';
$items['node/%node/revisions/%vid/view']['title arguments'] = array(
1,
3,
'view',
);
$items['node/%node/revisions/%vid/edit']['title callback'] = '_revisioning_ux_revisioning_title_for_edit_and_view';
$items['node/%node/revisions/%vid/edit']['title arguments'] = array(
1,
3,
'edit',
);
}