Re: getting $date



Graham Gough <graham@xxxxxxxxxxxx> wrote:

> perldoc -f localtime

That probably is what I'm looking for, but the perldoc page isn't (to
me, a newbie) very clear ..

Converts a time as returned by the time function to a 9-element
list with the time analyzed for the local time zone.
Typically
used as follows:

# 0 1 2 3 4 5 6 7 8
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst)
= localtime(time);

OK, so in my code, I put ...

my $date = localtime ($day, $mday, $year) ;

No surprises: it doesn't work.

All other combinations (locatime inside brackets, outside brackets, with
curly brackets, with $ in front, after, in the middle ..) don't work.

Help!

--
spam
.



Relevant Pages

  • Re: getting $date
    ... That probably is what I'm looking for, but the perldoc page isn't (to ... a newbie) very clear .. ... All other combinations (locatime inside brackets, outside brackets, with ... Josef Möllers ...
    (comp.lang.perl.misc)
  • Re: getting $date
    ... > spam wrote: ... a newbie) very clear .. ... >> Converts a time as returned by the time function to a 9-element ... >> All other combinations (locatime inside brackets, outside brackets, with ...
    (comp.lang.perl.misc)
  • Re: editing delimited record files
    ... >>> I am a Perl newbie ... ... I need to parse a validate the ... >> perldoc -f readline ...
    (comp.lang.perl.misc)
  • Re: editing delimited record files
    ... >> I am a Perl newbie ... ... >> into one common format. ... > perldoc -f readline ...
    (comp.lang.perl.misc)
  • Re: array question
    ... can you explain the brackets? ... Wich is ... perldoc perlretut # search for /whitespace/i ...
    (perl.beginners)