A WordPress-centric search engine for devs and theme authors

widget_nav_menu_args ›

apply_filters( 'widget_nav_menu_args', $nav_menu_args, $nav_menu, $args, $instance )
Parameters: (4)
  • (array) $nav_menu_args { An array of arguments passed to wp_nav_menu() to retrieve a navigation menu. @type callable|bool $fallback_cb Callback to fire if the menu doesn't exist. Default empty. @type mixed $menu Menu ID, slug, or name. }
    Required: Yes
  • (WP_Term) $nav_menu Nav menu object for the current menu.
    Required: Yes
  • (array) $args Display arguments for the current widget.
    Required: Yes
  • (array) $instance Array of settings for the current widget.
    Required: Yes
Defined at:

Filters the arguments for the Navigation Menu widget.


wp_nav_menu( apply_filters( 'widget_nav_menu_args', $nav_menu_args, $nav_menu, $args, $instance ) );