wp_nav_menu_{$menu->slug}_items WordPress Filter Hook
This hook is called when a new menu item is added to a menu. It allows you to add a new item to the menu before it is displayed.
apply_filters( "wp_nav_menu_{$menu->slug}_items", string $items , stdClass $args ) #
Filters the HTML list content for a specific navigation menu.
Description
See also
Parameters
- $items
(string)The HTML list content for the menu items.
- $args
(stdClass)An object containing wp_nav_menu() arguments.
Source
Changelog
Version | Description |
---|---|
3.0.0 | Introduced. |