wp_generator_type

Filters the output of the XHTML generator tag.

Description

apply_filters( 'wp_generator_type', (string) $xhtml ); 

Parameters (1)

0. $xhtml (string) => 'xhtml'
The XHTML generator.

Usage

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

Defined (1)

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

/wp-includes/general-template.php  
  1. the_generator( apply_filters( 'wp_generator_type', 'xhtml' ) );