Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Answer: How do I find today's date?

by Agyeya (Hermit)
on May 10, 2004 at 05:58 UTC ( #351975=categorized answer: print w/replies, xml ) Need Help??

Q&A > dates and times > How do I find today's date? - Answer contributed by Agyeya

You could also use Date::Manip
$date = ParseDate("today"); print "Today's Date is $date.\n";

Replies are listed 'Best First'.
Re: Answer: How do I find today's date?
by sacked (Hermit) on May 11, 2004 at 13:56 UTC
    If you want to make the date more human-readable, you can use Date::Manip::UnixDate to format it:
    $date = UnixDate( ParseDate("today") => '%b %e, %Y' ); print "Today's Date is $date.\n"; # MMM DD, YYYY (day is space-padded)

    --sacked
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
choroba mornings back
[Corion]: Hi choroba!
[Corion]: And Discipulus!
Corion arrived back from London. Always nice to meet people again, even if it's just once per year.
[Corion]: Also, dk contributed some cool stuff to App::ShaderToy, like menu settings and real fullscreen, eliminating many of my #TO-DO comments ;)
[Corion]: I hope you spent the four days well without me online ;-D
[Discipulus]: more or less Corion: the monastery was so calm, maybe too much! i feared you'v lost in VR
[Discipulus]: choroba can i ask why you used *DATA{IO}?

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (6)
As of 2016-12-06 08:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (101 votes). Check out past polls.