Topic: Style option for select

How do I set a style option in a select directly? In a text_field I used {'style' => 'width:50px'} and it works but it doesn't work in the select?

Re: Style option for select

Selects are complicated because there are so many arguments given to the select method.  But you do it like this:
<%= select :model, :attribute, [1,2,3], {}, {:style => ''} %>

Re: Style option for select

danger wrote:

Selects are complicated because there are so many arguments given to the select method.  But you do it like this:
<%= select :model, :attribute, [1,2,3], {}, {:style => ''} %>

So the values have to be there in order for it work? What is the {} between options and style?