- str_pad: documentation ( source)
<?php
$parts = [
'sec' => 1606329777,
'usec' => 5001,
'minuteswest' => -60,
'dsttime' => 0,
];
echo $parts['sec'] . '.' . $parts['usec'];
echo PHP_EOL;
echo $parts['sec'] . '.' . str_pad((string) $parts['usec'], 6, '0', STR_PAD_LEFT);