Opened 11 years ago
Closed 11 years ago
#33447 closed enhancement (fixed)
Introduce a nav menu title filter
| Reported by: | paulwilde | Owned by: | johnbillion |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.4 |
| Component: | Menus | Version: | 3.0 |
| Severity: | normal | Keywords: | has-patch |
| Cc: | Focuses: |
Description
Currently the only way to filter the output of a nav menu title is to use the the_title filter. This isn't ideal as this is also the filter used for the_title(). It also doesn't include any of the nav_menu specific arguments that are exposed inside the start_el() method except for the ID of the menu item.
I've attached a patch which introduces a separate filter for the title which includes the same arguments used by nav_menu_css_class, nav_menu_item_id, nav_menu_link_attributes and walker_nav_menu_start_el for consistency.
Attachments (2)
Change History (9)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
I think the filter should be named
nav_menu_item_titleinstead to avoid confusion with the menu title/name.