Format Values from a date_select

Hi

I have two date select options in a form, when I try and grab these
values using somthing like

@pMax = params[:max]

I get this in the varibale name

max(1i)2006max(2i)6max(3i)5

which has the correct data, jsut with added things like max(1i)

Whats the best way of grabbbing this data into a variable without the
extra titles?

Scott

ss wrote:

Whats the best way of grabbbing this data into a variable without the
extra titles?

Since it appears that the date is not destined for a (DB-backed) model
attribute of type Date, but for a plain instance variable, use
select_date
instead, with its prefix option set to ‘max’. Then in your controller:

m = params[:max]
@pMax = Date.new(m[:year], m[:month], m[:day])


We develop, watch us RoR, in numbers too big to ignore.