the_time filter-hookWP 0.71

Filters the time a post was written for display.

Usage

add_filter( 'the_time', 'wp_kama_the_time_filter', 10, 2 );

/**
 * Function for `the_time` filter-hook.
 * 
 * @param string $get_the_time The formatted time.
 * @param string $format       Format to use for retrieving the time the post was written. Accepts 'G', 'U', or PHP date format.
 *
 * @return string
 */
function wp_kama_the_time_filter( $get_the_time, $format ){

	// filter...
	return $get_the_time;
}
$get_the_time(string)
The formatted time.
$format(string)
Format to use for retrieving the time the post was written. Accepts 'G', 'U', or PHP date format.

Changelog

Since 0.71 Introduced.

Where the hook is called

the_time()
the_time
wp-includes/general-template.php 2694
echo apply_filters( 'the_time', get_the_time( $format ), $format );

Where the hook is used in WordPress

Usage not found.