[Rails] Re: date conversion

Justin Hernandez
Wed, 04 Jan 2006 01:59:33 -0000

Justin Hernandez wrote:
> I have the date saved in a database in the following format
> ''20060102170020''. How do I go about converting the date
in the format of
> January, 01, 1901? I searched all over and found something similiar
> using ''to_formatted_s''. However I only found support for
converting
> month to a three letter format (e.g. ''Jan''). Is there an
eaiser way?
> Thanks.

I found the answer. ''%B %d, %Y''.

--
Posted via http://www.ruby-forum.com/.