更新时间:2023-11-29 12:02:58
strtotime 会将您的日期字符串转换为 unix 时间戳.(自 Unix 时代以来的秒数.
strtotime will convert your date string to a unix time stamp. (seconds since the unix epoch.
$ts1 = strtotime($date1);
$ts2 = strtotime($date2);
$seconds_diff = $ts2 - $ts1;