in reply to Re: help on getting date
in thread help on getting date

Excellent post. Just one point which I would pick up on, is that values for the month, weekday and day of the year passed to POSIX::mktime begin at zero. As such, the determination of $then_time in your post should alternatively read:

my $then_time = POSIX::mktime ( 0, # Seconds 0, # Minutes 0, # Hours $date_parts[1], # Day (of month) $date_parts[0] - 1, # Month $date_parts[2] - 1900 # Year );

This behaviour is documented on the POSIX module man page.

 

perl -le 'print+unpack"N",pack"B32","00000000000000000000001001100100"'