wp-includes/general-template.php:5164Displays the generator XML or Comment for RSS, ATOM, etc.
$typestringOne hook fires while the_generator() runs, in this order:
Filters the output of the XHTML generator tag, for display.
function the_generator( $type ) { /** * Filters the output of the XHTML generator tag, for display. * * @since 2.5.0 * * @param string $generator_type The generator output. * @param string $type The type of generator to output. Accepts 'html', * 'xhtml', 'atom', 'rss2', 'rdf', 'comment', 'export'. */ echo apply_filters( 'the_generator', get_the_generator( $type ), $type ) . "\n";}Introduced in 2.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
src/wp-includes/general-template.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.