Am trying to build a search form but i want different select boxes to have different widths.when i use the select{ width:100% } in css it affects all select boxes in the application and when i try using css classes for instance select.search{width 100%} then try to add a class inside the select tag in my rails app <%=f.select(:source, options_for_select(@SourceList) ,:prompt => "Source",:class=>"search")%> it doesn't work.Am new in rails and need help to go around this.
select expects up to two hashes of options - the first are options for the select method itself (like prompt), and the second hash is for html options (class, style etc.). Also you I don't think you should be using options_for_select here - select calls it for you (but that argument should be something that options_for_select would understand).
Fred