RubyFlow The Ruby and Rails community linklog

×

The Ruby and Rails community linklog

Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!

Ruby 1.9 American Style Date Parsing

It would appear that all dates to Ruby 1.9 work as “dd/mm/yyyy”. I have made monkey patch to Ruby’s String that will allow ‘American’ (mm/dd/yyyy) style date processing in Rails to_date method.

Comments

Ah ah ah. :D

strftime is for you

these comments suck…

It would appear that all dates to Ruby 1.9 work as “dd/mm/yyyy”.

Seriously? That sucks. I thought if it were a Japanese thing, it’d be YYYY/MM/DD. (And I’m a Brit..)

Oh hai. dd/mm/yyy makes sense. kthnxbai

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in