I might have asked this before, but I don’t think I got a reply.
I’m using this code to create a drop-down menu of ‘cuisines’:
<%= select_tag “cuisine_id”,
options_from_collection_for_select(@cuisines, ‘id’, ‘name’) %>
My question is, how can I add an “All Cuisines” option to the start of
this menu, with a nil value? Or is there someway that lets you add a
similar option? It’s a common thing to have in a drop-down menu so I’m
sure it’s been discussed somewhere.
I’m guessing I’d probably have to code it more explicitly. Thanks!