$num_rows = rowCount($rsOfc); if ($num_rows > 0) { echo "<option value='0'>-Select Office-</option>\n"; for ($i = 1; $i <= $num_rows; $i++) { $rowOfc = getRows($rsOfc); echo "<option value='{$rowOfc['0']}'>{$rowOfc['1']}</option>\n"; $rowOfc = NULL; } } unset($rsOfc, $num_rows, $rowOfc); echo "</select>"; } if ($opn == 'personnel') { $office = isset($_GET['office']) ? $_GET['office'] : ""; echo "<select id='personnel' name='personnel' style='width:240px;' onchange='return personnel_change(this.value);'>\n"; $rsPer = fatch_personnel_ag_office($office); $num_rows = rowCount($rsPer); if ($num_rows > 0) { echo "<option value='0'>-Select Personnel-</option>\n"; for ($i = 1; $i <= $num_rows; $i++) { $rowPer = getRows($rsPer); echo "<option value='{$rowPer['0']}'>{$rowPer['0']}</option>\n"; $rowPer = NULL; } } unset($rsPer, $num_rows, $rowPer); echo "</select>"; } if ($opn == 'per_dtl') { $personcd = isset($_GET['personcd']) ? $_GET['personcd'] : ""; $epic = isset($_GET['epic']) ? $_GET['epic'] : "";
if ($num_rows > 0) { echo "<option value='0'>-Select Office-</option>\n"; for ($i = 1; $i <= $num_rows; $i++) { $rowOfc = getRows($rsOfc); echo "<option value='{$rowOfc['0']}'>{$rowOfc['2']}</option>\n"; $rowOfc = null; } } $rsOfc = null; $num_rows = 0; echo "</select>"; } if ($opn == 'personnel') { $office = $_GET['office']; $sub_div = $_GET['sub_div']; $rsPer = fatch_personnel_ag_office($sub_div, $office); $num_rows = rowCount($rsPer); if ($num_rows > 0) { for ($i = 1; $i <= $num_rows; $i++) { $rowPer = getRows($rsPer); echo "\n<input type='checkbox' id='chkbox{$i}' name='chkbox{$i}' /><label for='chkbox{$i}'>{$rowPer['0']}</label><br>\n"; echo "<input type='hidden' name='hidId{$i}' value='{$rowPer['0']}' />"; $rowPer = null; } } $rsPer = null; $num_rows = 0; } if ($opn == 'assembly') { $pc = $_GET['pc']; $sub_div = $_GET['sub_div'];