admin_head-nav-menus.php

The WordPress Core admin head nav menus php hook.

Description

add_action( 'admin_head-nav-menus.php', (string) $wp_delete_orphaned_draft_menu_items ); 

Parameters (1)

0. $wp_delete_orphaned_draft_menu_items (string) => '_wp_delete_orphaned_draft_menu_items'
The wp delete orphaned draft menu items.

Usage

To run the hook, copy the example below.
  1. // run the action 
  2. do_action( 'admin_head-nav-menus.php', $wp_delete_orphaned_draft_menu_items ); 
The following example is for adding a hook callback.
  1. // define the admin_head-nav-menus.php callback 
  2. function action_admin_head_nav_menus_php( $wp_delete_orphaned_draft_menu_items ) { 
  3. // make action magic happen here... 
  4. }; 
  5.  
  6. // add the action 
  7. add_action( 'admin_head-nav-menus.php', 'action_admin_head_nav_menus_php', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the action 
  2. remove_action( 'admin_head-nav-menus.php', 'action_admin_head_nav_menus_php', 10, 1 ); 

Defined (1)

The action is defined in the following location(s).

/wp-admin/includes/admin-filters.php  
  1. add_action( 'admin_head-nav-menus.php', '_wp_delete_orphaned_draft_menu_items' );