How to display date and time inside a form #markup?
Sounds like you want to use the format_date() function.

$now = time();
$date = format_date($now, 'short');


You can use it with any of the date formats that are defined in your system, or you can pass in a custom date string.