PHP7中文手册2018 带注释 最新chm版
function vtime($time) {
$output = '';
foreach (array(86400 => '天', 3600 => '小时', 60 => '分', 1 => '秒') as $key => $value) {
if ($time >= $key) $output .= floor($time/$key) . $value;
$time %= $key;
}
return $output;
}
转载请注明:谷谷点程序 » php vtime函数