This WordPress plugin adds a dynamic format which renders an output of a selected php callback function added via a filter hook.
Add piotrpress/dynamic_format/callbacks
filter.
add_filter( 'piotrpress/dynamic_format/callbacks', function( $callbacks ) {
$callbacks[ 'Current date' ] = function( $content ) { return date( 'Y-m-d H:i:s' ); };
return $callbacks;
} );
PHP >= 7.4
version.