You could also do it by hand, using a regex to extract the relevant info from your input-string and some hash-lookup to translate the month to a number:
HTH, Ratamy %convert = ( "Jan" => "01", "Feb" => "02", "Mar" => "03", "Jun" => +"06" ,); # ... you get the idea my $in = "Fri Jun 16 18:04:03 2012"; $in =~ /.*?\s(\w\w\w)\s(.*)$/; my $out = $convert{$1} . " " . $2;
In reply to Re: Conversion of Time
by Ratazong
in thread Conversion of Time
by PRS
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |