phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] CVS: phpgwapi/inc class.datetime.inc.php,1.5.2.11,1.


From: Ralf Becker <address@hidden>
Subject: [Phpgroupware-cvs] CVS: phpgwapi/inc class.datetime.inc.php,1.5.2.11,1.5.2.12
Date: Tue, 18 Mar 2003 12:52:35 -0500

Update of /cvsroot/phpgroupware/phpgwapi/inc
In directory subversions:/tmp/cvs-serv7239

Modified Files:
      Tag: Version-0_9_14-branch
        class.datetime.inc.php 
Log Message:
an other issue with daylight-saveing in days_between solved, now the 
calculation is down ignoring the daylight-saveing


Index: class.datetime.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/inc/class.datetime.inc.php,v
retrieving revision 1.5.2.11
retrieving revision 1.5.2.12
diff -C2 -r1.5.2.11 -r1.5.2.12
*** class.datetime.inc.php      26 Feb 2003 16:29:19 -0000      1.5.2.11
--- class.datetime.inc.php      18 Mar 2003 17:52:26 -0000      1.5.2.12
***************
*** 364,371 ****
                @author Steven Cramer/Ralf Becker
                @param $m1 - Month_1, $d1 - Day_1, $y1 - Year_1, $m2 - Month_2, 
$d2 - Day_2, $y2 - Year_2
                */
                function days_between($m1,$d1,$y1,$m2,$d2,$y2)
                {
!                       return intval((mktime(0,0,0,$m2,$d2,$y2) - 
mktime(0,0,0,$m1,$d1,$y1)) / 86400);
                }
  
--- 364,372 ----
                @author Steven Cramer/Ralf Becker
                @param $m1 - Month_1, $d1 - Day_1, $y1 - Year_1, $m2 - Month_2, 
$d2 - Day_2, $y2 - Year_2
+               @note the last param == 0, ensures that the calculation is 
always done without daylight-saveing
                */
                function days_between($m1,$d1,$y1,$m2,$d2,$y2)
                {
!                       return intval((mktime(0,0,0,$m2,$d2,$y2,0) - 
mktime(0,0,0,$m1,$d1,$y1,0)) / 86400);
                }
  





reply via email to

[Prev in Thread] Current Thread [Next in Thread]