Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
选择标签:-
<%=select_tag "names",options_from_collection_for_select(@users,"id","name",@user.id)%>
现在我的下拉列表看起来像这样:-
john matt sara
但我想拥有它: -
john edit matt edit sara edit
其中“编辑”是可以编辑特定用户的链接。但我无法将链接放入 select_tag。
谢谢
There's no way to do this in Rails out of the box - this is rather uncommon task. Yet I see two options here:
select
divs