[eluser]Unknown[/eluser]
OK, so I have set up the validation helper perfectly on my 'Add new entry' page and it works great.
Now I'm building the 'Edit entry' page and can't figure out how to combine the validation helper with pre-populating the form with the saved data.
Using the form helper I need to populate the inputs like this:
Code:
// Scheme name
$this->table->add_row(
array(
form_label('Scheme name', 's_name').NBS.form_error('s_name'),
form_input(
array(
'id' => 's_name',
'name' => 's_name',
'class' => 'field',
'value' => $scheme->s_name
)
)
)
);
But without the:
Code:
'value' => set_value('s_name')
bit, how will the validation work?
Am I missing something obvious?
Many thanks,
Malcolm