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
209           $attributes = '';
210           foreach ( $atts as $attr => $value ) {
211                if ( is_scalar( $value ) && '' !== $value && false !== $value ) {
212                     $value       = ( 'href' === $attr ) ? esc_url( $value ) : esc_attr( $value );
213                     $attributes .= ' ' . $attr . '="' . $value . '"';
214                }
215           }
216
217           /** This filter is documented in wp-includes/post-template.php */
218           $title = apply_filters( 'the_title', $menu_item->title, $menu_item->ID );
219
220           /**
221            * Filters a menu item's title.
222            *
223            * @since 4.4.0
224            *
225            * @param string   $title     The menu item's title.
226            * @param WP_Post  $menu_item The current menu item object.
227            * @param stdClass $args      An object of wp_nav_menu() arguments.