>
>How about Time::Local?
>
>#!/usr/bin/perl
>use strict;
>use warnings;
>use Time::Local;
>
>my %month;
>@month{ qw/Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec/ } = 0..11;
>
>my $date = "Thu Mar 9 23:04:03 2006";
>
>my (undef, $month, $day, $h, $m, $s, $year) = split /\W+/, $date;
>
>my $tim
- Original Message -
From: "Jeff Pang" <[EMAIL PROTECTED]>
Newsgroups: perl.beginners
To:
Sent: Thursday, March 09, 2006 10:09 AM
Subject: how to translate time string
Hello,list,
Maybe it's a simple problem,but I don't know how to do it.
I have a time s
On 3/9/06, Jeff Pang <[EMAIL PROTECTED]> wrote:
> I have a time string,for example:
> Thu Mar 9 23:04:03 2006
>
> How can I get it translated to unix timestamp,for example:
> 1141916656
Have you looked on CPAN?
http://search.cpan.org/search?query=time&mode=all
Hope this helps!
--Tom Phoeni
Jeff Pang wrote:
Hello,list,
Maybe it's a simple problem,but I don't know how to do it.
I have a time string,for example:
Thu Mar 9 23:04:03 2006
How can I get it translated to unix timestamp,for example:
1141916656
Thanks.
--
Jeff Pang
NetEase AntiSpam Team
http://corp.netease.com
POSI
Hello,list,
Maybe it's a simple problem,but I don't know how to do it.
I have a time string,for example:
Thu Mar 9 23:04:03 2006
How can I get it translated to unix timestamp,for example:
1141916656
Thanks.
--
Jeff Pang
NetEase AntiSpam Team
http://corp.netease.com
--
To unsubscribe, e-mai