[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Posix function question



At 00.48 -0400 1998.07.24, Awrobinson@aol.com wrote:
>One of the examples in Lincoln Stein's book "Official Guide to Programming
>With CGI.pm" uses the Posix strftime() function. It didn't work with MacPerl.
>I got what I expected with the date formats, but not the time formats. '%r' is
>supposed to give the time in 12 hour format, but all it printed was "r".

So you mean it does not work as expected, or maybe even does not work
properly.  But surely POSIX::strftime() works.


>Likewise for '%Y' for 24 hour time.

%Y is the 4-digit year, not a time.  It works as expected for me.


>Can anyone tell me what the formats are for the MacPerl version of strftime()
>or point me to the equivalent of my "system's manpage"?

Well, Date::Format also has strftime, and time2str (which uses time()
instead of an array).  I have heard less than glowing things about it, but
it has worked in my experience, and %r works as expected.

However, it seems the POSIX::strftime() misbehavior with %r is a bug.

--
Chris Nandor          mailto:pudge@pobox.com         http://pudge.net/
%PGPKey = ('B76E72AD', [1024, '0824090B CE73CA10  1FF77F13 8180B6B6'])

***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch