function shareaholic_menu in Share Buttons, Related Posts, Content Analytics - Shareaholic 7.3
Same name and namespace in other branches
- 8 shareaholic.module \shareaholic_menu()
Implementation of hook_menu()
Establishes "routes" for the Shareaholic module
Return value
The menu structure containing link to settings page
File
- ./
shareaholic.module, line 59 - Allows site owner to add share buttons/recommendations on their website
Code
function shareaholic_menu() {
// this creates the block for shareaholic in config page
$menu['admin/config/shareaholic'] = array(
'title' => 'Shareaholic',
'description' => 'Shareaholic Module Settings',
'weight' => 1,
'page callback' => 'system_admin_menu_block_page',
'access arguments' => array(
'access administration pages',
),
'file' => 'system.admin.inc',
'file path' => drupal_get_path('module', 'system'),
'position' => 'left',
);
// Path to the shareaholic advanced page
$menu['admin/config/shareaholic/advanced'] = array(
'title' => 'Shareaholic Advanced Settings',
'description' => 'Advanced settings for the Shareaholic module',
'page callback' => 'shareaholic_admin_advanced',
'access arguments' => array(
'administer site configuration',
),
'type' => MENU_NORMAL_ITEM,
'weight' => 2,
);
// Path to the shareaholic app manager page
$menu['admin/config/shareaholic/settings'] = array(
'title' => 'Shareaholic App Manager',
'description' => 'Manage various Social Tools like Share Buttons and Related Posts',
'page callback' => 'shareaholic_admin_settings',
'access arguments' => array(
'administer site configuration',
),
'type' => MENU_NORMAL_ITEM,
'weight' => 1,
);
// Path for the shareaholic share count API
$menu['shareaholic/api/share_counts/v1'] = array(
'page callback' => 'shareaholic_share_counts_api',
'type' => MENU_CALLBACK,
'access callback' => TRUE,
);
return $menu;
}