
abockover
Deleted
Jul 24, 2000, 10:16 AM
Post #1 of 3
(626 views)
|
|
Program suffers from Y2K bug!!!
|
Can't Post
|
|
Help! My search engine suffers from the Y2K bug! When a user searches for something on my site and a list of matching files are found, each file has a date on it. this is displayed like: June 25, 100 it needs to be displayed like: June 25, 2000 Below is the code for the date sub: <BLOCKQUOTE><font size="1" face="Arial,Helvetica,sans serif">code:</font><HR> sub formattedDate { my($date) = @_; ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime($date); @months = ('Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'); if ($year<100) {$year += 1900;} $fdate = "$months[$mon] $mday, $year"; return $fdate; } </pre><HR></BLOCKQUOTE> Please tell me what I need to do to fix this Y2K bug. Thanks, Aaron
|