Never been to DZone Snippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Create an RFC822 compliant date in Perl (See related posts)

use Date::Manip qw(ParseDate UnixDate);

# Create an RFC822 compliant date (current time)
my $rfc822_format = "%a, %d %b %Y %H:%M %Z";
my $today         = ParseDate("Now");

my $rfc822_date   = UnixDate($today,$rfc822_format);


You need to create an account or log in to post comments to this site.


Click here to browse all 4860 code snippets

Related Posts