Opened 3 years ago
Closed 3 years ago
#13366 closed enhancement (fixed)
Enhance item filtering capabilities on walk_nav_menu_tree
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.0 |
| Component: | Menus | Version: | 3.0 |
| Severity: | normal | Keywords: | |
| Cc: |
Description
Could it be possible in "wp-includes/nav-menu-template.php" at line 104 to change :
$output .= apply_filters( 'wp_get_nav_menu_item', $item_output, $args);
for:
$output .= apply_filters( 'wp_get_nav_menu_item', $item_output, $args, $item );
so it will possible to insert information (item ID, alt, ...) trough sprintf before or after item
Thanks
Change History (1)
Note: See
TracTickets for help on using
tickets.

(In [14600]) s/wp_get_nav_menu_item/walker_nav_menu_start_el/ to be more specific. Pass all start_el() args to the filter. Props tomtomp. fixes #13366