[ruby-it] Questionario con Rails

Luigi Maresca marluigi a libero.it
Gio 14 Maggio 2009 13:45:09 CEST


> <table border = 1>
> <% for question in @questions %>
> <tr>
> <td><%= question.id %></td>
> <td><%= question.domanda %></td>
> <td><%= radio_button( :answer, :risposta, value="0" )%></td>
> <td><%= radio_button( :answer, :risposta, value="1" )%></td>
> <td><%= radio_button( :answer, :risposta, value="2" )%></td>
> <% end %>
> </tr>
> </table>

Forse l'errore che hai fatto inizialmente sta nel fatto che il tag di 
chiusura della riga </tr> l'hai messo fuori del ciclo for mentre 
l'apertura è dentro!

Luigi
-- 
Posted via http://www.ruby-forum.com/.


More information about the Ml mailing list