Freedom to Write
Tuesday 9 August 2011
Set Date for a Logfile
sub SetDate
{
my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time);
$year+=1900;
$mon++;
my $CurDate = sprintf("%02d/%02d/$year %02d:%02d:%02d",$mon,$mday,$hour,$min,$sec);
return $CurDate;
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
Tweets by @sriramperumalla
No comments:
Post a Comment