Forum: Ruby on Rails ActiveResource and dates

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
jason (Guest)
on 2007-05-14 15:12
(Received via mailing list)
I'm having difficulty using form date_select on a date attribute when
using ActiveResource.

The xml attribute looks like:

<date type="date">yyyy-mm-dd</date>

And the form is simple form_for scaffolding:

form_for :model do |f|

f.date_select :date


When I run this I get the following error:

undefined method `day' for "2006-05-09":String

I think I have to do something with the attribute type but I'm unsure
exactly what and where.


jason (Guest)
on 2007-05-14 15:58
(Received via mailing list)
Solution = Date.parse(

in the client controller.
This topic is locked and can not be replied to.