Re: DATE Question

From: Date: Sun, 05 Oct 2003 22:52:45 +0000
Subject: Re: DATE Question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-165108@lists.php.net to get a copy of this message
--- Shaun <shaun@mania.plus.com> wrote: > is there a function in PHP that will work out the amount of time(hours) > beween two different dates / times? You can just subtract the timestamps the find the number of seconds between any two times. PHP has a rich set of functions to help you generate timestamps if you only have a text representation (05 Oct 2003) as well as functions to help you format dates. See here for more: http://www.php.net/manual/en/ref.datetime.php One of the first user comments looks to be a function that combines a few of these other functions together to do something like you are wanting. Hope that helps. Chris ===== My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp

« previous php.general (#165108) next »