【发布时间】:2012-05-12 18:00:47
【问题描述】:
可能重复:
How to calculate the difference between two dates using PHP?
Date Difference in php?
我在一个变量中有两个日期
$fdate = "2011-09-01"
$ldate = "2012-06-06"
现在我需要它们之间的月差。
例如,如果您从 09 月(9 月)到明年 06 月(6 月)计算,答案应该是 10 - 结果是 10。
如何在 PHP 中做到这一点?
【问题讨论】:
-
类似问题link