menu.install 1.16 KB
Newer Older
1
2
3
4
5
6
7
<?php
// $Id$

/**
 * Implementation of hook_install().
 */
function menu_install() {
8
9
  // Create tables.
  drupal_install_schema('menu');
10
11
12
  db_query("INSERT INTO {menu_custom} (menu_name, title, description) VALUES ('navigation', 'Navigation', 'The navigation menu is provided by Drupal and is the main interactive menu for any site. It is usually the only menu that contains personalized links for authenticated users, and is often not even visible to anonymous users.')");
  db_query("INSERT INTO {menu_custom} (menu_name, title, description) VALUES ('primary_links', 'Primary links', 'Primary links are often used at the theme layer to show the major sections of a site. A typical representation for primary links would be tabs along the top.')");
  db_query("INSERT INTO {menu_custom} (menu_name, title, description) VALUES ('secondary_links', 'Secondary links', 'Secondary links are often used for pages like legal notices, contact details, and other secondary navigation items that play a lesser role than primary links')");
13
14
15
16
17
18
}

/**
 * Implementation of hook_uninstall().
 */
function menu_uninstall() {
19
20
  // Remove tables.
  drupal_uninstall_schema('menu');
21
22
  menu_rebuild();
}