# Generating a textfield with an array as arguments

**URL:** <https://www.ruby-forum.com/t/generating-a-textfield-with-an-array-as-arguments/108220>\
**Category:** Rails\
**Created:** [June 30, 2007, 8:44am UTC](https://www.ruby-forum.com/t/generating-a-textfield-with-an-array-as-arguments/108220 "2007-06-30T08:44:00Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![T-Parent](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/51bf81/32.png) [@T-Parent](https://www.ruby-forum.com/u/T-Parent)\
**Post date:** [June 30, 2007, 8:44am UTC](https://www.ruby-forum.com/t/generating-a-textfield-with-an-array-as-arguments/108220/1 "2007-06-30T08:44:00Z")

</div>

Hi everyone,

I have an array which looks like this ( output taken from  
debug(display\_options) ):

* * *

- rows: “5”
- cols: “40”

I am trying to generate a textfield using the ‘text\_field’ helper  
function and my array (let’s call it display\_options):

text\_field ‘field’,  
field.id,  
{:value =\> field.value, display\_options}

I tried using the splat operator ( \*display\_options), but it gives me  
a whole bunch of errors.

Anyone knows how to do this?

Thank you,

T-Parent
