/** * parseTypeSelect */ protected function parseTypeSelect($selected_id) { $Type = new ecommerce_promotion_type(); $records = $Type->listing(); foreach ($records as $item) { if ($item['id'] == $selected_id) { $item['selected'] = 'selected="selected"'; } $this->tpl->assign("ITEM", $item); $this->tpl->parse("content.form.type.item"); } $this->tpl->parse("content.form.type"); }