Dan Weaver wrote:
> Hi,
> 
> I'm trying to put a css class on a dropdown box built using a select
> helper (to make it wider) but I can't get it to take.  I thought for
> sure, and from what I've seen elsewhere, this code should work:
> 
> <%= f.select :month, 1..12, :selected => Time.now.month.to_i, :class =>
> 'monthSelect' %>

You have to make sure Ruby sees two separate hash arguments:

<%= f.select :month, 1..12, {:selected => Time.now.month.to_i},
                             :class => 'monthSelect' %>

-- 
Rails Wheels - Find Plugins, List & Sell Plugins - http://railswheels.com

--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to