[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] CVS: phpgwapi/inc class.datetime.inc.php,1.14,1.15
From: |
Ralf Becker <address@hidden> |
Subject: |
[Phpgroupware-cvs] CVS: phpgwapi/inc class.datetime.inc.php,1.14,1.15 |
Date: |
Fri, 18 Apr 2003 04:37:06 -0400 |
Update of /cvsroot/phpgroupware/phpgwapi/inc
In directory subversions:/tmp/cvs-serv14268
Modified Files:
class.datetime.inc.php
Log Message:
fix for bug reported on user-list, time-compare creates date before 1970/1/1
which is the earliest allowed date on windows
Index: class.datetime.inc.php
===================================================================
RCS file: /cvsroot/phpgroupware/phpgwapi/inc/class.datetime.inc.php,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** class.datetime.inc.php 18 Mar 2003 18:02:36 -0000 1.14
--- class.datetime.inc.php 18 Apr 2003 08:37:04 -0000 1.15
***************
*** 455,460 ****
function
time_compare($a_hour,$a_minute,$a_second,$b_hour,$b_minute,$b_second)
{
! $a_time =
mktime(intval($a_hour),intval($a_minute),intval($a_second),0,0,70);
! $b_time =
mktime(intval($b_hour),intval($b_minute),intval($b_second),0,0,70);
if($a_time == $b_time)
{
--- 455,462 ----
function
time_compare($a_hour,$a_minute,$a_second,$b_hour,$b_minute,$b_second)
{
! // I use the 1970/1/2 to compare the times, as the 1.
can get via TZ-offest still
! // before 1970/1/1, which is the earliest date allowed
on windows
! $a_time =
mktime(intval($a_hour),intval($a_minute),intval($a_second),1,2,1970);
! $b_time =
mktime(intval($b_hour),intval($b_minute),intval($b_second),1,2,1970);
if($a_time == $b_time)
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] CVS: phpgwapi/inc class.datetime.inc.php,1.14,1.15,
Ralf Becker <address@hidden> <=