in reply to Best way to print out a particular date-time format (very specific)

I usually use Time::Piece, which will override CORE::localtime to return an object of Time::Piece class, like this:

use Time::Piece; my $tp = localtime; print $tp->strftime("%d%b%y:%H:%M:%S");

Beside that, you can get the year, month, hour, etc by just calling its methods

-cheepy-
  • Comment on Re: Best way to print out a particular date-time format (very specific)
  • Download Code