/**
* 两个时间戳之间的间隔天数,按照日期算
* @param $time1
* @param $time2
* @return mixed
*/
function interval_days($time1,$time2)
{
$cha = date_diff(date_create(date('Ymd', $time1)), date_create(date('Ymd', $time2)));
return $cha->days;
} 如果帮助到你,请赏杯奶茶喝~
- 本文链接: https://www.shx1024.top//index/article/details/article_id/54.shtml
- 版权声明:本博客所有文章除特别声明外,均默认采用 许可协议。