$stamp = (strtotime($_POST[‘start‘])-strtotime($_POST[‘end‘])); $s = $stamp%60; //秒 $m_stamp= ($stamp-$s)/60; $m = $m_stamp%60; //分 $h_stamp=($m_stamp-$m)/60; $h= $h_stamp%24; $d = ($h_stamp-$h)/24; echo "$d 天 $h 小时$m 分钟 $s 秒"; echo "<br>";
时间: 2024-09-27 07:24:03