Welcome Guest, Not a member yet? Register   Sign In
forms - text area...am I misssing somthing?
#1

[eluser]weetstraw[/eluser]
Hello. I have question which I'm assuming is an oversight on my part.

To control the size of a text area I would like to use the following code:
Code:
form_textarea('description','description','20','20')

but it doesn't change the col/row, Instead I have to use the code below which seems unnecessary.

Code:
function addRecord()
{
    $data['title']=" - Manage Content - Add Content";
    $data['heading']="Add Record";
    $data['formAction']="manage/insertRecord";
    
    $ta=array(
        'name'=>'description',
        'value'=>'description',
        'cols'=>'50',
        'rows'=>'15'
    );
    
    $data['formField']=array(
        form_input('title','title'),
        form_input('link','link'),
        form_input('tags','tags'),
        form_textarea($ta)
        );

    $this->load->view('form_view',$data);
}
#2

[eluser]kgill[/eluser]
Sadly, what'd you'd like and what you get are often two radically different things. Wink The function doesn't work like that, you could hack it up to create your own version that does what you want, live with passing an array or option 3 bribe/beg the powers that be to change it in the next release.
#3

[eluser]weetstraw[/eluser]
got it to work...can't believe how obvious it was.
Code:
form_textarea(array('name'=>'description','value'=>'description','cols'=>'50','rows'=>'15'))




Theme © iAndrew 2016 - Forum software by © MyBB