in reply to convert month number to month name
Hash is up to the rescue
outputmy %month_name; @month_name{ 0 .. 11 } = qw(Jan Feb Mar Apr May Jun Jul Aug Sept Oct N +ov Dec); my ( $day, $month, $year ) = (localtime)[ 3, 4, 5 ]; $year = $year + 1900; print join " ", $day, $month_name{$month}, $year;
30 Aug 2012
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: convert month number to month name
by dsheroh (Monsignor) on Aug 30, 2012 at 09:59 UTC |