如何在 codeigniter 的下拉数组中使用 set_select() (表单助手的一部分):
它用于记住用户选择了哪个选项。
$guide_options = array('investments' => 'Investments',
'wills' => 'Wills',
'tax-planning' => 'Tax planning',
'life-insurance' => 'Life insurance',
'currency-exchange' => 'Currency exchange',
'retirement-planning' => 'Retirement planning',
'international-healthcare' => 'International healthcare',
'savings-plans' => 'Savings plans',
'education-planning' => 'Education planning',
'sipps' => 'SIPPS',
'qrops' => 'QROPS',
'qnups' => 'QNUPS',
'mortgages' => 'Mortgages',
'other' => 'Other service'
);
echo form_dropdown('guide', $guide_options, 'investments');
表单助手指南:http: //codeigniter.com/user_guide/helpers/form_helper.html