Forum Moderators: coopster & phranque

Message Too Old, No Replies

perl's time command

perl's time command

         

SandraR

3:58 am on Jul 14, 2005 (gmt 0)

10+ Year Member



I found this script that requires the end date to be formatted in perl's time. Does anyone have a way to convert normal time and date to?

There example:

$endtime = 847443600;
# Time it ends (as returned by perl's time command)

Thanks in advanced for any help.

SeanW

12:36 pm on Jul 14, 2005 (gmt 0)

10+ Year Member



Date::Manip is very flexible in converting any text date format into the unix style seconds since epoch.

Sean

MichaelBluejay

1:54 am on Jul 15, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



use Time::Local;
($Second, $Minute, $Hour, $Day, $Month, $Year, $WeekDay, $DayOfYear, $IsDST) = localtime($endtime);