wp_get_nav_menu_items WordPress Filter Hook
The wp_get_nav_menu_items hook is used to retrieve the list of menu items for a given menu. This can be used to create a custom navigation menu or to modify an existing one.
apply_filters( 'wp_get_nav_menu_items', array $items , object $menu , array $args ) #
Filters the navigation menu items being returned.
Parameters
- $items
(array)An array of menu item post objects.
- $menu
(object)The menu object.
- $args
(array)An array of arguments used to retrieve menu item objects.
Source
File: wp-includes/nav-menu.php
Changelog
Version | Description |
---|---|
3.0.0 | Introduced. |