navigation_markup_template

Filters the navigation markup template.

Description

(string) apply_filters( 'navigation_markup_template', (string) $template, (string) $class ); 

Note: The filtered template HTML must contain specifiers for the navigation class (%1$s), the screen-reader-text value (%2$s), and placement of the navigation links (%3$s):

%2$s

Returns (string)

Navigation template.

Parameters (2)

0. $template (string)
The default template.
1. $class (string)
The class passed by the calling function.

Usage

To run the hook, copy the example below.
  1. $template = apply_filters( 'navigation_markup_template', $template, $class ); 
  2.  
  3. if ( !empty( $template ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the navigation_markup_template callback 
  2. function filter_navigation_markup_template( $template, $class ) { 
  3. // make filter magic happen here... 
  4. return $template
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'navigation_markup_template', 'filter_navigation_markup_template', 10, 2 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'navigation_markup_template', 'filter_navigation_markup_template', 10, 2 ); 

Defined (1)

The filter is defined in the following location(s).

/wp-includes/link-template.php  
  1. $template = apply_filters( 'navigation_markup_template', $template, $class );