Skip to content
Docs
Get RestroPress

Filter

rpress_local_date

Updated
On this page

Filters the localized date string returned by rpress_local_date().

Runs after the date has been converted to the site timezone and formatted. If the input could not be parsed, the original string is passed through.

Parameters#

ParameterTypeDescription
$local_datestringThe formatted date.
$datestringThe original date string passed to the function.

Return value#

string. The localized date.

Example#

function my_local_date( $local_date, $date ) {
	return $local_date;
}
add_filter( 'rpress_local_date', 'my_local_date', 10, 2 );

Source#

Applied in:

  • includes/rp-core-functions.php (line 815), in rpress_local_date()

See also#

Was this page helpful?