[erlang-questions] strftime for formatting dates and times
Tue Jun 21 17:28:41 CEST 2011
Would love this being integrated into calendar! (Or appropriate module,
although I think calendar should be the one)
Kenny Stone wrote:
> I literally copied ruby's strftime docs into the readme and implemented
> (almost) each type of formatting.
> I'm considering patching the calendar module with this functionality.
> strftime:f(now(), "Printed on %m/%d/%Y"). %=> "Printed on 11/19/2007"
> strftime:f(now(), "at %I:%M%p"). %=> "at 08:37AM"
> strftime:f(now(), "at %I:%M%p", universal). %=> "at 02:37PM"
> strftime:f(now(), "%D-%T.%N"). %=>
> erlang-questions mailing list
More information about the erlang-questions