note 61674 added to function.date

From: Date: Thu, 09 Feb 2006 07:06:28 +0000
Subject: note 61674 added to function.date
Groups: php.notes 
Request: Send a blank email to php-notes+get-103347@lists.php.net to get a copy of this message
VERY SIMPLY CONVERT GMT TO YOUR TIMEZONE! set the $TimeDiff with number of hours difference your time zone is from GMT. Example (PST with Day light savings accounted for): ****************************************** ****************************************** $TimeDiff = 7+date('I'); $TimeZoneEpoc = time() - ($TimeDiff*60*60); $currentDate = date('n/j/y',$TimeZoneEpoc); $currentTime = date('g:i A',$TimeZoneEpoc); ****************************************** ****************************************** the "date('I')" part is where it accounts for day light savings. ---- Server IP: 216.194.113.175 Probable Submitter: 12.108.11.17 ---- Manual Page -- http://www.php.net/manual/en/function.date.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+61674 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes&reason=non-english Delete: already in docs -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes&reason=already+in+docs Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+61674&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+61674&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#103347) next »