Solution for : How to calculate minute difference between two date-times in PHP?
Below is the simple example fo achieve the solution:
1 2 3 | $to_time = strtotime ( "2008-12-13 10:42:00" ); $from_time = strtotime ( "2008-12-13 10:21:00" ); echo round ( abs ( $to_time - $from_time ) / 60,2). " minute" ; |
No comments:
Post a Comment