How do you set a custom id when using a check_box_tag helper in rails?
I have a loop which creates a bunch of checkboxes based on a collection:
- subject
Think I figured it out...
- subject.syllabus_references.each do |sr| = check_box_tag "question[syllabus_reference][#{sr.id}]", sr.id = label_tag "question[syllabus_reference][#{sr.id}]", sr.name
This works but if you have a better way let me know!