[Tutos-commits] CVS: tutos/php Date.pinc,1.41,1.42 address.pinc,1.53,1.54 address_ins.php,1.20,1.21
Projects / CRM / PLM / Calendar / Tasks / SCRUM / Test / Inventory
Brought to you by:
gokohnert
From: Gero K. <gok...@us...> - 2001-12-31 09:48:49
|
Update of /cvsroot/tutos/tutos/php In directory usw-pr-cvs1:/tmp/cvs-serv21945/php Modified Files: Date.pinc address.pinc address_ins.php Log Message: Bugfix: Birthday without TZ Index: Date.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/Date.pinc,v retrieving revision 1.41 retrieving revision 1.42 diff -C2 -r1.41 -r1.42 *** Date.pinc 2001/12/06 09:43:08 1.41 --- Date.pinc 2001/12/31 09:48:46 1.42 *************** *** 323,327 **** * ts is assumed in current_users TZ */ ! function setDateTimeTS($ts) { global $current_user; --- 323,327 ---- * ts is assumed in current_users TZ */ ! function setDateTimeTS($ts,$notz = 0) { global $current_user; *************** *** 339,343 **** $this->format = "TS"; $this->ts_def = $ts; ! if ( $current_user->offset != 0 ) { $this->ts_def -= $current_user->offset; } --- 339,343 ---- $this->format = "TS"; $this->ts_def = $ts; ! if ( ($current_user->offset != 0) && ($notz == 0) ) { $this->ts_def -= $current_user->offset; } *************** *** 346,350 **** * set DateTime by variables (incoming variables are in the users TZ) */ ! function setDateTimeF($str) { global $HTTP_GET_VARS , $HTTP_POST_VARS , $current_user; --- 346,350 ---- * set DateTime by variables (incoming variables are in the users TZ) */ ! function setDateTimeF($str,$notz = 0) { global $HTTP_GET_VARS , $HTTP_POST_VARS , $current_user; *************** *** 403,407 **** $this->ts = mktime($this->hour,$this->min,$this->sec,$this->month,$this->day,$this->year); $this->ts_def = $this->ts; ! if ( $current_user->offset != 0 ) { $this->ts_def -= $current_user->offset; } --- 403,407 ---- $this->ts = mktime($this->hour,$this->min,$this->sec,$this->month,$this->day,$this->year); $this->ts_def = $this->ts; ! if ( ($current_user->offset != 0) && ($notz == 0) ) { $this->ts_def -= $current_user->offset; } *************** *** 435,439 **** * */ ! function setDateTime($str) { global $current_user , $tutos; --- 435,439 ---- * */ ! function setDateTime($str,$notz = 0) { global $current_user , $tutos; *************** *** 573,577 **** $this->ts_def = $this->ts; ! if ( $current_user->offset != 0 ) { $this->ts += $current_user->offset; // Set the fields according to offset --- 573,577 ---- $this->ts_def = $this->ts; ! if ( ($current_user->offset != 0) && ($notz == 0) ) { $this->ts += $current_user->offset; // Set the fields according to offset Index: address.pinc =================================================================== RCS file: /cvsroot/tutos/tutos/php/address.pinc,v retrieving revision 1.53 retrieving revision 1.54 diff -C2 -r1.53 -r1.54 *** address.pinc 2001/12/18 12:20:20 1.53 --- address.pinc 2001/12/31 09:48:46 1.54 *************** *** 58,62 **** } ! $this->birthday->setDateTime($r->get($pos, "birthday")); $this->readTeamList(); --- 58,62 ---- } ! $this->birthday->setDateTime($r->get($pos, "birthday"),1); $this->readTeamList(); Index: address_ins.php =================================================================== RCS file: /cvsroot/tutos/tutos/php/address_ins.php,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -r1.20 -r1.21 *** address_ins.php 2001/12/18 06:33:15 1.20 --- address_ins.php 2001/12/31 09:48:46 1.21 *************** *** 31,35 **** $birthday = new DateTime(0); ! $birthday->setDateTimeF("birthday"); --- 31,35 ---- $birthday = new DateTime(0); ! $birthday->setDateTimeF("birthday",1); |