如果有人能帮助我,这将是伟大的确定它是简单的东西,但对于我的生活我无法找到如何做到这一点我有两个时间戳,我想将它们加在一起( $ timestamp1 + $ timestamp2)我有第一部分想通了,但我不能得到我想要这样的结果到目前为止,我有这个两个时间戳总结在一起
$flight_time = strtotime($flight_time_1)+strtotime($flight_time_2)+strtotime($flight_time_3)+strtotime($flight_time_4)+strtotime($flight_time_5)+strtotime($flight_time_6)+strtotime($flight_time_7)+strtotime($flight_time_8)+strtotime($flight_time_9)+strtotime($flight_time_10);
$flight_time = date("H:i:s", $flight_time);
,并且给了我时间16时20分○○秒这是完美 第二代码我有这
$sqlcow = "SELECT system_flight FROM uav_checks WHERE uav_id = '$registration'";
$result1cow=mysql_query($sqlcow);
while ($arow = mysql_fetch_array($result1cow)){
$system_flight2 = $arow['system_flight'];
}
并与此代码我得到th是28:07:00这是完美的
我需要的是这16时20分00秒+ 28:07:00
然而,当我试图给他们以各种方式,我知道可能加在一起,它不会工作所以我难倒请谁能帮助我
谢谢
想要的结果是什么? – 2014-09-30 14:22:14
您可能正在使用**绝对时间**,这意味着时间戳具有**年,月和日**信息。这就是为什么它可能不起作用。 – tfrascaroli 2014-09-30 14:25:37
[这个问题](http://stackoverflow.com/questions/11556731/how-we-can-add-two-date-intervals-in-php)(和接受的答案)可能会有所帮助。 – 2014-09-30 14:28:28