in reply to simple question

No one has mentioned it but you don't typically shell out to date in perl. Perl has lots of date handling built in. See localtime gmtime and lots of other stuff like Date::Manip Date::Calc Time::Local

my $string_time = localtime(time()); my $yesterday = localtime(time()-24*60*60); my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time); print "$string_time\n$yesterday\n"; printf "%02d:%02d:%02d %02d/%02d/%4d\n", $hour, $min, $sec, $mday, $mo +n+1, $year+1900;

HTH

cheers

tachyon