|There's more than one way to do things|
perlman:Time::Localby root (Scribe)
|on Dec 23, 1999 at 00:53 UTC||Need Help??|
See the current Perl documentation for Time::Local.
Here is our local, out-dated (pre-5.6) version:
Time::Local - efficiently compute time from local and GMT time
$time = timelocal($sec,$min,$hours,$mday,$mon,$year); $time = timegm($sec,$min,$hours,$mday,$mon,$year);
These routines are quite efficient and yet are always guaranteed to agree with
timelocal is implemented using the same cache. We just assume that we're translating a
GMT time, and then fudge it when we're done for the timezone and daylight savings arguments. The timezone is determined by examining the result of
Both routines return -1 if the integer limit is hit. I.e. for dates after the 1st of January, 2038 on most machines.