You are here

function og_menu_edit_menu_form in Organic Groups Menu (OG Menu) 6

Same name and namespace in other branches
  1. 6.2 og_menu.module \og_menu_edit_menu_form()
  2. 7.3 og_menu.pages.inc \og_menu_edit_menu_form()
  3. 7.2 og_menu.pages.inc \og_menu_edit_menu_form()

Menu callback; Build the form that handles the adding/editing of a custom menu.

1 string reference to 'og_menu_edit_menu_form'
og_menu_menu in ./og_menu.module
Implementation of hook_menu().

File

./og_menu.module, line 341
Integrates Menu with Organic Groups. Lots of menu forms duplication in OG context.

Code

function og_menu_edit_menu_form(&$form_state, $type, $menu = array()) {
  module_load_include('inc', 'menu', 'menu.admin');
  $node = menu_get_object('node', 1);
  $form = drupal_retrieve_form('menu_edit_menu', $form_state, $type, $menu);
  $form['og_menu_gid'] = array(
    '#type' => 'value',
    '#value' => $node->nid,
  );
  $form['#submit'][] = 'menu_edit_menu_submit';
  $form['#submit'][] = 'og_menu_edit_menu_form_submit';
  $form['#submit'][] = 'og_menu_edit_menu_form_submit_redirect';
  $form['delete']['#submit'][] = 'og_menu_delete_menu_form_submit';
  return $form;
}