dthacker has asked for the wisdom of the Perl Monks concerning the following question:
sub get_time_stamp() { my @tan=Today_and_Now(); my $stamp=join '', @tan[0..4]; return $stamp; }
Unfortunately this is giving me YYYYMDDHHMM instead of YYYYMMDDHHMM. Is there a more effective way of getting the string I want than padding the output of Today_and_Now?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Creating a string for a date stamp
by danboo (Beadle) on Sep 20, 2001 at 00:39 UTC | |
|
Re: Creating a date stamp (Russ: POSIX::strftime)
by Russ (Deacon) on Sep 20, 2001 at 01:19 UTC | |
|
Re: Creating a string for a date stamp
by mitd (Curate) on Sep 20, 2001 at 05:08 UTC |