Archive

Posts Tagged ‘hours’

How To Know the Difference or Time Duration Between Two Dates in PHP

December 14th, 2009 Masino Sinaga No comments

Have you ever got difficulty when you want to calculate the difference or the time duration between two dates by using PHP? For example, the first date is ’2009-12-01 11:12:13′, and the second date is ’2009-12-04 14:15:16′, so the difference or the time duration between this two dates will give a result as: ’3 Day(s), 3 Hour(s), 3 Minute(s), 3 Second(s).’. We will make the function in order to make you easy to implement this calculation in your PHP code. Please note that your date format must be in this order: ‘yyyy-MM-dd hh:mm:ss’ as possible, otherwise, this function will not work properly, I guess. Read more…

  • Share/Bookmark

Sum Time with Format hh:mm:ss by Using PHP

October 14th, 2009 Masino Sinaga 2 comments

Have you ever got the difficulty when you want to sum the two time and display its result with format hours:minutes:seconds by using PHP? Well, now you don’t have to worry about it. This following code will give you the solution. Read more…

  • Share/Bookmark
Categories: General Tags: , , , , , , ,