- date_diff: documentation ( source)
- date_default_timezone_set: documentation ( source)
<?php
date_default_timezone_set('Europe/London');
echo "<date>";
echo "|| This is a TEST || Oxygen8 - Haiti Appeal 2013 || Total Raised so far : £0 :( || ";
/*
print gmdate("D H:i:s",time());
*/
$datetime1 = new DateTime('now');
$datetime2 = new DateTime('tomorrow 09:00:00');
$interval = date_diff($datetime1,$datetime2);
echo $interval->format('%H:%i:%s to go!');
echo "</date>";
/*
$d1 = new DateTime();
$d2 = new DateTime('21:00:00');
$d3 = new DateTime('09:00:00');
$d4=$d2->diff($d1);
$d5=$d3->diff($d1);
echo $d4->format(' %h:%i:%s is 21:00?');
echo $d5->format(' %h:%i:%s is 9:00?');
*/
?>