Filters the HTML attributes applied to a page menu item’s anchor element.
Parameters
$attsarray- The HTML attributes applied to the menu item’s
<a>element, empty strings are ignored.
hrefstringThe href attribute.aria-currentstringThe aria-current attribute.
$pageWP_Post- Page data object.
$depthint- Depth of page, used for padding.
$argsarray- An array of arguments.
$current_page_idint- ID of the current page.
Source
$atts = apply_filters( 'page_menu_link_attributes', $atts, $page, $depth, $args, $current_page_id );
Changelog
| Version | Description |
|---|---|
| 4.8.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.