difference between two times? Date_diff and DateTime::diff

[email protected] (Matthew Croud)
Newsgroups php.general
Message-ID <[email protected]>
Hello,

My journey of learning PHP is going well, so i've decided to make a  
small program which works out the difference between two times and  
records the data in a text file.

I've searched the PHP manual for functions which can help me out, and  
I discovered the function Date_diff ( http://uk3.php.net/manual/en/function.date-diff.php 
  )and the class DateTime::diff ( http://uk3.php.net/manual/en/datetime.diff.php 
  )

My question is, how on earth do I use these functions ? I really don't  
understand the manual documentation.

I've just moved onto the subject of classes and so I'm fairly new to  
the concept, although I am following it well.

If someone could explain to me how to use ether of these ( Date_diff  
and DateTime::diff ) I would be VERY grateful.

Thank you so much!
Matt
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.