Time::Local let me faint
- From: practicalperl@xxxxxxxxx (Practical Perl)
- Date: Wed, 30 Aug 2006 00:48:26 +0800
Hello,lists,
Please see these two lines' output:
[$ perl -Mstrict -MTime::Local -le 'print timelocal(0,0,0,31,8,2006)'
Day '31' out of range 1..30 at -e line 1
$ perl -Mstrict -MTime::Local -le 'print timelocal(0,0,0,31,7,2006)'
1156953600
I translate the time of '2006-7-31 00:00:00' to unix timestamp,it's
successful.
But when I translate the time of '2006-8-31 00:00:00' to unix timestamp,it
said '31 out of range'.
I'm so faint that August doesn't have 31th day?Please tell me why this
happen and how to resolve it.
Thank you very much.
- Follow-Ups:
- Re: Time::Local let me faint
- From: John W. Krahn
- Re: Time::Local let me faint
- From: Flemming Greve Skovengaard
- Re: Time::Local let me faint
- From: Adriano Ferreira
- Re: Time::Local let me faint
- Prev by Date: Re: splitting strings
- Next by Date: Re: help with awk command in perl
- Previous by thread: Cgi with GD grap, and displaying graphs
- Next by thread: Re: Time::Local let me faint
- Index(es):