use POSIX qw( strftime ); # Formats as "6:45pm 10/31/2008" $time = strftime('%I:%M%p %m/%d/%Y', localtime($_[0]));