........ $output .= '<div class="formclass"><form name="name" method="post" action="">' . showCB() . ''; $output .= '</form></div>'; ........
function showCB() {
global $modx;
global $_lang;
$sectortable = $modx->getFullTableName('jobsector');
$sectors = $modx->db->select('id,name', $sectortable,'','id ASC');
$show_Combo_Box = ""
."<select size=\"1\" name=\"selectsector\">"
."<option value=\"0\">" . $_lang['EM_sel_sector'] . "</option>";
WHILE ($row = mysql_fetch_array($sectors)) {
$show_Combo_Box .= ""
."<OPTION value=\"".$row[0]."\">"
.$row[1]
."</OPTION>";
}
$show_Combo_Box .= ""
."</SELECT>";
return $show_Combo_Box;
}