controller
1@fluits = [{"りんご"=>apple, "バナナ"=>banana, "みかん"=>orange}]
view
1<% @fluits.each do |fluit| %> 2<%= fluit["りんご"] %> 3<% end %> 4
controller
1a = <%= fluit["りんご"] %> 2
みたいな感じにしたいのですが、どのようにすればいいのでしょうか?
回答1件
あなたの回答
tips
プレビュー
投稿2018/10/25 04:10
編集2018/10/25 04:38controller
1@fluits = [{"りんご"=>apple, "バナナ"=>banana, "みかん"=>orange}]
view
1<% @fluits.each do |fluit| %> 2<%= fluit["りんご"] %> 3<% end %> 4
controller
1a = <%= fluit["りんご"] %> 2
みたいな感じにしたいのですが、どのようにすればいいのでしょうか?
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2018/10/25 04:54