# Date\_select bug in Rails 1.2.2

**URL:** <https://www.ruby-forum.com/t/date-select-bug-in-rails-1-2-2/86746>\
**Category:** Rails\
**Created:** [February 25, 2007, 8:54am UTC](https://www.ruby-forum.com/t/date-select-bug-in-rails-1-2-2/86746 "2007-02-25T08:54:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Yue\_Teng](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/3ec8ea/32.png) [@Yue\_Teng](https://www.ruby-forum.com/u/Yue_Teng)\
**Post date:** [February 25, 2007, 8:54am UTC](https://www.ruby-forum.com/t/date-select-bug-in-rails-1-2-2/86746/1 "2007-02-25T08:54:04Z")

</div>

I have just upgraded to Rails 1.2.2 and date\_select seems to be having a  
problem. In Rails 1.2.2,

\<%= date\_select ‘so\_header’, ‘date’ %\>

expands to:

Date  
2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 January February March April May June July August September October November December 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

Notice that the name of the day field is corrupted as:

name=“use\_hiddendiscard\_hourtruediscard\_typetrueorderyearmonthdayhourminutesecondprefixso\_header[date(3i)][day]”\>

and therefore the date when selected cannot be parsed by ROR properly.

I have confirmed that Rails 1.1.6 works OK and the bug occurs only in  
1.2.1 and 1.2.2.

Has anyone else encountered this?
