| CPAN Ratings Time-Format reviews | |
| Home | Search | About | Bitcard Account | Login |
RSS | Module Info | Add a review of Time-Format
Yeah! Finally a decent date-time format handling module!..
I don't have to do this anymore:
sub timestring {
my @t = localtime( shift || time );
my $t
= sprintf( "%04d", $t[5] + 1900 ) . '-'
. sprintf( "%02d", $t[4] + 1 ) . '-'
. sprintf( "%02d", $t[3] ) . ' '
. sprintf( "%02d", $t[2] ) . ':'
. sprintf( "%02d", $t[1] ) . ':'
. sprintf( "%02d", $t[0] );
return $t;
}
I can just just use this:
$time{'yyyy-mm-dd hh:mm:ss'}
Great job!..
Topchyan - 2008-05-28T11:14:41
exactly what i needed, thanx a lot to Mr.Eric !
jai - 2003-08-20T08:36:07
|
Perl.org sites
: bugs
| dev
| history
| jobs
| learn
| lists
| use
Site Information and Contacts |
|