wp_get_associated_nav_menu_items
wp_get_associated_nav_menu_items ( $object_id = 0, $object_type = 'post_type', $taxonomy = '' )
Parameters:- (int) object_id Optional. The ID of the original object. Default 0.
- (string) object_type Optional. The type of object, such as 'post_type' or 'taxonomy'. Default 'post_type'.
- (string) taxonomy Optional. If $object_type is 'taxonomy', $taxonomy is the name of the tax that $object_id belongs to. Default empty.
Returns:- (int[]) The array of menu item IDs; empty array if none.
Defined at: - Introduced in WordPress: 3.0.0
- Deprecated in WordPress: —
Description
Returns the menu items associated with a particular object.