# How to fill out textarea in html form

**URL:** <https://www.ruby-forum.com/t/how-to-fill-out-textarea-in-html-form/149113>\
**Category:** Ruby\
**Created:** [September 20, 2008, 7:45pm UTC](https://www.ruby-forum.com/t/how-to-fill-out-textarea-in-html-form/149113 "2008-09-20T19:45:01Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![terrytie](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/22d042/32.png) [@terrytie](https://www.ruby-forum.com/u/terrytie)\
**Post date:** [September 20, 2008, 7:45pm UTC](https://www.ruby-forum.com/t/how-to-fill-out-textarea-in-html-form/149113/1 "2008-09-20T19:45:01Z")

</div>

Hi,

So sorry for this naive question … I’m new to ruby as of several days  
ago.

I’m porting some CGI code from perl and I’m trying to use the Ruby CGI  
objects to do everything. In one of my forms I’ve got a cgi.textarea  
that I would like to populate with text taken from an mSQL database. To  
do this I was using a DBI.prepare and then fetching each row. I think  
this might work fine if I was formatting the html directly since I could  
puts it to the standard output. But I can’t figure out how to have the  
text appear inside the textarea defined by cgi.textarea.

Any help or suggestions would be much appreciated.

Thanks,  
Terry
