Hi Guys,
Can anyone recommend a way to have a drop down menu that show a list of
directories?
In my controller I have:
@files = [Dir.glob(''/mydirectoryofcoolfiles/*'') ]
Then the form I am unsure of how to do it:
<%= f.collection_select :job_id, @files, :id, :job_title, :prompt =>
"Select a shot" %>
The app has a directory with lots of ''job'' directories in it.
Each job folder has a number of ''asset'' folders in it.
I want the user to select a ''job'' in a dropdown menu, and then
a second
menu lists the folders in that particular folder
any ideas?
Thanks
Adam
--
Posted via http://www.ruby-forum.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
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---