Problems with date_select

Is is possible to have both a default value specified, and to include a blank in a date_select?

<%= date_select('birthday_date', 'value', {:default => birthday, :start_year => 1900, :end_year => Time.now.year, :order => [:month, :day, :year], :include_blank => true, }) %>

This should technically include a blank option, and when the page loads it should select to the date that is being passed in.

However, when I pass in a valid birthday that is a DateTime object, the select defaults to the blank values instead of the dates in the datetime object. If I take out the :include_blank => true statement, it default to the birthday correctly.

Is this intended functionality? If so, is there any way to achieve what I am trying to do?

Thanks.

It seems to be that "birthday_date" may not be an object but a variable. date_select expects an object_name as the first parameter and the method in the second date_select(object_name, method, options)

If you are not passing in an object, perhaps you should try select_date helper instead. Something like: select_date(birthday_date, { :start_year => 1900, :end_year => Time.now.year, :order =>

[:month, :day, :year], :include_blank => true, })

Just my guess.

steve