Here's a snippet of code I use to refresh my memory from time to time as to
what localtime() returns.

($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime();

The only thing you have to remember is that the $mon variable is actually
one less than the current month(it starts at 0), and you must add 1900 to
the $year variable to get the current year.

Example:
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime();
$mon++;
$year = $year + 1900;

print "Today is   : $mon/$mday/$year\n";
print "The time is: $hour:$min:$sec\n";


-----Original Message-----
From: Jason Purdy [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 29, 2002 8:25 AM
To: Amy sing; [EMAIL PROTECTED]
Subject: Re: TIME


I'm sure you'll get a lot of feedback on this, but here's my first stab: 
Check out 'perldoc -f localtime'

localtime is the function I believe you're looking for, which will return an

array of local time information that you can use however you want.

Jason

If memory serves me right, on Tuesday 29 January 2002 11:17, Amy sing wrote:
> Does anyone have a script that will give the local
> time.. please help..
>
> __________________________________________________
> Do You Yahoo!?
> Great stuff seeking new owners in Yahoo! Auctions!
> http://auctions.yahoo.com

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--------------------------------------------------------------------------------
This email may contain confidential and privileged 
material for the sole use of the intended recipient. 
If you are not the intended recipient, please contact 
the sender and delete all copies.

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to