wp_get_associated_nav_menu_items


wp_get_associated_nav_menu_items ( $object_id = 0, $object_type = 'post_type', $taxonomy = '' )

Parameters:
  • (int) $object_id The ID of the original object.
  • (string) $object_type The type of object, such as "taxonomy" or "post_type."
  • (string) $taxonomy If $object_type is "taxonomy", $taxonomy is the name of the tax that $object_id belongs to
Returns:
  • (array) The array of menu item IDs; empty array if none;
Defined at:

Description

Get the menu items associated with a particular object.

Related Functions

wp_get_nav_menu_items, wp_save_nav_menu_items, _sort_nav_menu_items, wp_update_nav_menu_item, wp_setup_nav_menu_item

Top Google Results

User discussions

wpseek mobile