Hi- Using date select for a query and when I try and print the result to make sure I am getting the right date, I get this: start_year2007ordermonthdayyear(2i)2start_year2007ordermonthdayyear(3i)14start_year2007ordermonthdayyear(1i)2008 View: <%= date_select ''startdate'',:start_year=>2007,:order => [:month,:day,:year] %></p> Controller: @start = params[:startdate] Result View: <%= @start %> What''s up? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Also, this date_select is not for a model, I would like to parse the date to be used outside the model... On Feb 14, 2:58 pm, pete <peterbattag...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi- > > Using date select for a query and when I try and print the result to > make sure I am getting the right date, I get this: > start_year2007ordermonthdayyear(2i)2start_year2007ordermonthdayyear(3i)14start_year2007ordermonthdayyear(1i)2008 > > View: > <%= date_select ''startdate'',:start_year=>2007,:order => > [:month,:day,:year] %></p> > > Controller: > @start = params[:startdate] > > Result View: > <%= @start %> > > What''s up?--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Found this for anyone else who may have the same question... http://snippets.dzone.com/tag/date_select On Feb 15, 3:03 pm, pete <peterbattag...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Also, this date_select is not for a model, I would like to parse the > date to be used outside the model... > > On Feb 14, 2:58 pm, pete <peterbattag...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Hi- > > > Using date select for a query and when I try and print the result to > > make sure I am getting the right date, I get this: > > start_year2007ordermonthdayyear(2i)2start_year2007ordermonthdayyear(3i)14start_year2007ordermonthdayyear(1i)2008 > > > View: > > <%= date_select ''startdate'',:start_year=>2007,:order => > > [:month,:day,:year] %></p> > > > Controller: > > @start = params[:startdate] > > > Result View: > > <%= @start %> > > > What''s up?--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---