I have this form and a yes or no radio choice. The get_request_ids(song) basically gives me the ids i need.
<% form_tag '/somewhere' do -%>
<% [ 'yes', 'no' ].each do |status| %>
<%= radio_button_tag "group[]#{get_request_ids(song)}", "#{status}[#{get_request_ids(song)}]" %>
<%= status.humanize %>
<% end %>
<tr><td><%= submit_tag 'Save' %></td></tr>
<% end %>
The html looks like this
<input id="group_1,2_yes12" name="group[]1,2" value="yes[1,2]" type="radio">
Yes
<input id="group_1,2_no12" name="group[]1,2" value="no[1,2]" type="radio">
No
<input id="group_3,6,7_yes367" name="group[]3,6,7" value="yes[3,6,7]" type="radio">
Yes
<input id="group_3,6,7_no367" name="group[]3,6,7" value="no[3,6,7]" type="radio">
No
the params looks like this
group"=>[{"1,2"=>"yes[1,2]", "3,6,7"=>"no[3,6,7]"}]
i can parse this to get the yes requests and the no request but there has got to be a better way...I feel like this is a hack