[thelist] Date returning 20100

CDitty mail at redhotsweeps.com
Mon Jul 3 09:05:34 CDT 2000


Can someone tell me why this routine is returning 20100 instead of 2000?

@date = localtime(time);     #puts the current time/date into an array
$day = $date[3] + 1;         #have to add 1 since it returns days starting at 0
$month = $date[4] + 1;       #same with the month
$yr = "20" . $date[5];       #only returns a 2 digit year, change 19 to 20 
after y2k
print "$yr\n";

Thanks

CDitty





More information about the thelist mailing list