格式化日期求差

1 $startdate=strtotime("2009-9-5");
2 $enddate=strtotime("2009-9-18");   
3 $days=round(($enddate-$startdate)/3600/24) ;
4 echo $days;  

 

posted @ 2013-03-27 22:31  /折磨  阅读(100)  评论(0编辑  收藏  举报