- Code: Select all
function getTime($iSeconds)
{
$sHH = str_pad(intval(intval($iSeconds / 3600)), 2, "0", STR_PAD_LEFT);
$sMM = str_pad(intval(($iSeconds / 60) % 60), 2, "0", STR_PAD_LEFT);
$sSS = str_pad(intval($iSeconds % 60), 2, "0", STR_PAD_LEFT);
return ($sHH.":".$sMM.":".$sSS);
}