date_diff() will certainly do the job, however, if the dates are stored as UNIX timestamps, there is no need to go through creating DateTime objects etc. Performing simple arithmetic gives you the difference in seconds. IMO all dates should be stored as timestamps precisely so simple arithmetic can be used for date calculations. There are functions that will translate timestamps to and from other formats. For example, just about any date formatted text can be translated to a timestamp by using strtotime().
Of course you can create a DateTime object from the same date formatted text and use class methods. Different ways to achieve the same end.
]]>