customize_nav_menu_available_items WordPress Filter Hook
The customize_nav_menu_available_items hook allows you to add custom items to the list of available menu items when creating a new menu in the WordPress Customizer. This can be useful if you want to add a custom link or other item to your menu that is not part of the default WordPress menu system.
apply_filters( 'customize_nav_menu_available_items', array $items , string $object_type , string $object_name , int $page ) #
Filters the available menu items.
Parameters
- $items
(array)The array of menu items.
- $object_type
(string)The object type.
- $object_name
(string)The object name.
- $page
(int)The current page number.
Source
Changelog
Version | Description |
---|---|
4.3.0 | Introduced. |