June 30th, 2006, 03:02 PM
ROR - Display value in <textarea>
I'm returning queried DB values in a form for editing. I can't get Ruby to display the value in a <textarea>! The value displays fine in a table row, or in a text box, but the textarea doesn't work. Anyone know if there is something special that the textarea needs? (This query only returns one row BTW)Thanks!!
<% @edit.each do |cause| %>
<td nowrap align="right">PRIMARY(a):</td>
<td colspan="2"><textarea wrap name="cause_texta" value="<%= cause.cause_texta %>" rows="6" cols="70"></textarea>
<% end %>
June 30th, 2006, 03:22 PM
The text should go between the textarea tags, not in the value attribute.
June 30th, 2006, 04:34 PM
OMG - now I KNOW I'm burned out on Ruby!! Sheesh, I've only been coding HTML for what - 6 years?? What a dumba$$ -- I need a vacation...
Thank you O mighty Penguin!