I am trying to calculate the date and time difference between two values. I have searched the net for a simple method to calculate the difference but I can seem to find one!!! Ones which I have found dont seem to work!
The format of the date and time are of iso 8601 format. Like 2004-02-12T15:19:21+00:00
I tried using the one posted by date_diff in link:
http://uk.php.net/manual/en/function.date-diff.php
That doesnt seem to work given certain dates and times and whilst changing it is an option I can imagine it getting into a bit of beast!!!!
There currently is a dateTime diff method for php > 5.3 version but I have a requirement to stay with version 5.2
http://uk.php.net/manual/en/datetime.diff.php
Hope someone can help.