Hi
I have an array of string and I want to use it in collection_select rails function..
['cassiano', 'roloff']
to use in...
<%= collection_select 'form', 'field', @my_array? %>
Thanks for help
Hi
I have an array of string and I want to use it in collection_select rails function..
['cassiano', 'roloff']
to use in...
<%= collection_select 'form', 'field', @my_array? %>
Thanks for help
Cassiano,
<%= select_tag "field", options_for_select(@my_array, @my_array[0]) %>