/*
* ComputeDateDifference(...)
* Description:
* Calculates the difference between two dates.
*
* Parameter:
* $m0, $d0, $y0 => 1. Moth/Day/Year
* $m1, $d1, $y1 => 2. Moth/Day/Year
*
* Return:
* Difference between given dates in days.
*
* Autor:
* 06.06.2006 - Christian Meyer <ryker@ridgex.net>
*/
function ComputeDateDifference($m0,$d0,$y0,$m1,$d1,$y1)
{
$x0 = gregoriantojd($m0,$d0,$y0);
$x1 = gregoriantojd($m1,$d1,$y1);
$diff = $x1 - $x0;
if ($diff < 0)
$diff *= -1; // abs
return $diff;
}