function dynamic_background_menu in Dynamic Background 6
Same name and namespace in other branches
- 7.2 dynamic_background.module \dynamic_background_menu()
- 7 dynamic_background.module \dynamic_background_menu()
Implementation of hook_menu().
File
- ./
dynamic_background.module, line 28 - This module enables administrators to upload images used as background on the site. The selected background image link is exposed as either $background in the page.tpl file or as /background.css.
Code
function dynamic_background_menu() {
$items = array();
$items['admin/build/backgrounds'] = array(
'title' => 'Dynamic background',
'description' => t('Upload background images.'),
'page callback' => 'drupal_get_form',
'page arguments' => array(
'dynamic_background_admin_images',
),
'access arguments' => array(
'set dynamic backgrounds',
),
'file' => 'includes/backgrounds.admin.inc',
);
$items['admin/build/backgrounds/images'] = array(
'title' => 'Background images',
'description' => t('Upload background images and select current active background.'),
'type' => MENU_DEFAULT_LOCAL_TASK,
'weight' => -10,
);
$items['admin/build/backgrounds/settings'] = array(
'title' => 'Settings',
'description' => t('Configure dynamic backgrounds settings'),
'page callback' => 'drupal_get_form',
'page arguments' => array(
'dynamic_background_admin_settings',
),
'access arguments' => array(
'configure dynamic backgrounds',
),
'type' => MENU_LOCAL_TASK,
'weight' => -5,
'file' => 'includes/settings.admin.inc',
);
$items['background.css'] = array(
'page callback' => 'dynamic_background_css',
'access arguments' => array(
'dynamic backgrounds css',
),
'type' => MENU_CALLBACK,
);
return $items;
}