In case this helps anyone else, I now have:

form_controller.rb:

def index
@members_group =
[
["Molecular Neuroscience", [["Prof. Dr. Denise Manahan-Vaughan", "1"], 
["Prof. Dr. Lutz Pott", "2"]]],
["Developmental Neuroscience", [["Prof. Dr. Petra Wahle", "3"], ["Prof. 
Dr. Andreas Faissner", "4"], ["Dr. Alexander von Holst", "5"]]],
["Systems Neuroscience", [["Prof. Dr. Dr. Hanns Hatt", "6"], ["Prof. Dr. 
Klemens Stoertkuhl", "7"]]],
["Cognitive Neuroscience", [["Prof. Dr. Dr. h.c. Onur Guentuerkuen", 
"8"], ["Prof. Dr. Irene Daum", "9"], ["Prof. Dr. Oliver T. Wolf", 
"10"]]],
["Clinical Neuroscience", [["Prof. Dr. Martin Tegenthoff", "11"]]],
["Computational  Neuroscience", [["Prof. Dr. Gregor Schoener", "12"], 
["Jun. Prof. Dr. Christian Igel", "13"], ["Dr. Rolf Wuertz", "14"]]],
]

@applicant = Applicant.new(params[:applicant])
if(request.post? and @applicant.save)
  @name = "public/pdfs/#...@applicant.last_name}.pdf"
  redirect_to :action => "success"
else
  @member_1 = @applicant.member_1
  render :action=> "index"
end
end

In form.html.erb:
...
<%= select_tag "applicant[member_1]", 
grouped_options_for_select(@members_group, selected_key = @member_1, 
prompt = " ") %>

This works perfectly.

-- 
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@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to