Hello Everyone.

I have make Form with use of set_value('Name'); in codeigniter
but In Input type Textarea not given value.



$last_goals = '';
if($this->session->userdata('user_from') == 'log') //After login value come From db                     
    $last_goals = $getdesired[0]->ds_goals;
    $last_goals = set_value('career_goals');  // without login this value come

$data = array('id'=>'id_career_goals',

echo form_textarea($data);


Any can suggest me what wrong with me.

Thank you.

I have same problem Link

Solution: It's work..

Add Blank Rule.

$this->form_validation->set_rules('field_name', '', '');

In textarea you are trying to echo set_value() similar to input field.but in textarea value can retain only if you giving the value between<textarea><?php echo set_value('name'); ?></textarea>

ravi142 He is not asking for validation.

I know about <textarea><?php echo set_value('name'); ?></textarea> but i want to put in above code.that why i have post code.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.