You are here

function modernizr_menu in Modernizr 7.3

Same name and namespace in other branches
  1. 8 modernizr.module \modernizr_menu()
  2. 7.2 modernizr.module \modernizr_menu()

Implements hook_menu().

File

./modernizr.module, line 143
Main module file for Modernizr

Code

function modernizr_menu() {
  $items = array();

  // Rebuild Modernizr
  $items['admin/config/development/modernizr/rebuild'] = array(
    'title' => 'Rebuild Modernizr',
    'description' => 'Queries Drupal for Modernizr dependencies and generates a custom link to the Modernizr builder.',
    'page callback' => 'modernizr_generate_url',
    'file' => 'modernizr.admin.inc',
    'type' => MENU_DEFAULT_LOCAL_TASK,
    'access arguments' => array(
      'administer modernizr',
    ),
  );

  // Module settings
  $items['admin/config/development/modernizr/settings'] = array(
    'title' => 'Modernizr settings',
    'description' => 'Administrative settings for Modernizr module.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'modernizr_admin',
    ),
    'file' => 'modernizr.admin.inc',
    'type' => MENU_LOCAL_TASK,
    'access arguments' => array(
      'administer modernizr',
    ),
  );

  // Admin menu item (duplicate of "Rebuild Modernizr")
  $items['admin/config/development/modernizr'] = array(
    'title' => 'Modernizr',
    'description' => 'Queries Drupal for Modernizr dependencies and generates a custom link to the Modernizr builder.',
    'page callback' => 'modernizr_generate_url',
    'file' => 'modernizr.admin.inc',
    'type' => MENU_NORMAL_ITEM,
    'access arguments' => array(
      'administer modernizr',
    ),
  );
  return $items;
}