[TYPO3-dev] Time issues - a proposal
Franz Holzinger
franz at fholzinger.com
Sat Oct 27 07:55:07 CEST 2007
Hello
> * A function that outputs the date/time specified for a specific BE user
> for the timezone and the output format he selected
> * A function that transfers a date / time a BE user entered in a form
> (in his format and his timezone) into a valid UTC timestamp again.
have a look at
EXT:sr_feuser_register/pi1/class.tx_srfeuserregister_pi1_adodb_time.php
FUNCTION adodb_date2($fmt, $isoDateString = false)
Same as adodb_date, but 2nd parameter accepts iso date, eg.
adodb_date2('d-M-Y H:i','2003-12-25 13:01:34');
FUNCTION adodb_gmdate($fmt, $timestamp = false)
Convert a timestamp to a formatted GMT date. If $timestamp is not
defined, the
current timestamp is used. Unlike the function date(), it supports dates
outside the 1901 to 2038 range.
FUNCTION adodb_mktime($hr, $min, $sec [, $month, $day, $year])
Converts a local date to a unix timestamp. Unlike the function
mktime(), it supports
dates outside the 1901 to 2038 range. Differs from mktime() in that all
parameters
are currently compulsory.
FUNCTION adodb_gmmktime($hr, $min, $sec [, $month, $day, $year])
Converts a gmt date to a unix timestamp. Unlike the function
gmmktime(), it supports
dates outside the 1901 to 2038 range. Differs from gmmktime() in that
all parameters
are currently compulsory.
Useful url for generating test timestamps:
http://www.4webhelp.net/us/timestamp.php
- Franz
More information about the TYPO3-dev
mailing list