function date_get_gmt_diff in Date 6
Get local time zone offset from GMT.
Return value
timezone offset in seconds
3 calls to date_get_gmt_diff()
- _date_date in date_php4/
date_php4_lib.inc - Low level function to create date() for pre-1970 and post-2038 dates.
- _date_getdate in date_php4/
date_php4_lib.inc - Low-level function that returns the getdate() array for pre-1970 and post-2038 dates.
- _date_mktime in date_php4/
date_php4_lib.inc - Low level function to create mktime() for pre-1970 and post 2038 dates.
File
- date_php4/
date_php4.inc, line 935
Code
function date_get_gmt_diff() {
static $TZ;
if (isset($TZ)) {
return $TZ;
}
$TZ = mktime(0, 0, 0, 1, 2, 1970, 0) - gmmktime(0, 0, 0, 1, 2, 1970, 0);
return $TZ;
}