I have a Date object ( from Pear) and want to subtract another Date object to get the time difference in seconds.
I have tried a few things but the first just gave
To do it without pear, to find the seconds 'till 17:00 you can do:
$current_time = mktime (); $target_time = strtotime (date ('Y-m-d'. ' 17:00:00')); $timediff = $target_time - $current_time;
Not tested it, but it should do what you need.