Hello everybody,
I have a collection_select:
f.collection_select(:selected_id, @subcategories, :id, :cat_transl)
which turns into the following tags:
<option value="4">Deutsch</option>
<option value="5">Chinesisch</option>
<option value="6">Spanisch</option>
<option value="10">Mathematik</option>
What I want is to add a attribute to every option
<option value="4" parent="3">Deutsch</option>
<option value="5" parent="3">Chinesisch</option>
<option value="6" parent="3">Spanisch</option>
<option value="10" parent="9">Mathematik</option>
How is this possible?
Thanks Markus