• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Repopulate a multi_select dropdown?

#1
[eluser]TerryT[/eluser]
Anyone point me in the right direction on solving how to repopulate a multi_select drop down when another part of a form fails validation? A version of the 2.0.2 manual on exxenmedia.com says:

Or to re-populate the field you would use:
Code:
<input type="text" name="options[]" value="<?php echo set_value('options[]'); ?>" size="50" />

The manual here doesn't really say.

I have tried:

Code:
$this->data['projects'] = array('name' => 'projects[]',
    'id' => 'projects',
    'type' => 'text',
    'value' => $this->form_validation->set_value('projects[]'),
   );

but it doesn't repopulate. Thanks for any direction.


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.