Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Using Time::Piece Strptime

by stevieb (Canon)
on Jan 25, 2016 at 22:24 UTC ( [id://1153619]=note: print w/replies, xml ) Need Help??


in reply to Using Time::Piece Strptime

Welcome to the Monastery, GrorkGnom!

Please show us the code that you're using to output the date. Here's an example that appears to get you what you want. Review the last line... the input is one thing, but it's how you output it that makes the difference:

use Time::Piece; my $date = "Mon Jan 25 15:19:50 GMT 2016"; my $date1 = Time::Piece->strptime($date, "%a %b %d %H:%M:%S %Z %Y"); # code you're interested in is below here print join ' ', $date1->wdayname, $date1->monname, $date1->mday, $date +1->year;

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1153619]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (1)
As of 2024-04-25 05:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found