Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: the_title

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
250            * }
251            * @param WP_Post  $menu_item The current menu item object.
252            * @param stdClass $args      An object of wp_nav_menu() arguments.
253            * @param int      $depth     Depth of menu item. Used for padding.
254            */
255           $atts       = apply_filters( 'nav_menu_link_attributes', $atts, $menu_item, $args, $depth );
256           $attributes = $this->build_atts( $atts );
257
258           /** This filter is documented in wp-includes/post-template.php */
259           $title = apply_filters( 'the_title', $menu_item->title, $menu_item->ID );
260
261           /**
262            * Filters a menu item's title.
263            *
264            * @since 4.4.0
265            *
266            * @param string   $title     The menu item's title.
267            * @param WP_Post  $menu_item The current menu item object.
268            * @param stdClass $args      An object of wp_nav_menu() arguments.