Beispiel #1
0
            if (strlen($strError) <= 0) {
                if (strlen($_REQUEST['save']) > 0) {
                    LocalRedirect("form_field_list.php?WEB_FORM_ID=" . $WEB_FORM_ID . "&additional=" . $additional . "&lang=" . LANGUAGE_ID);
                } else {
                    LocalRedirect("form_field_edit.php?ID=" . $ID . "&WEB_FORM_ID=" . $WEB_FORM_ID . "&additional=" . $additional . "&lang=" . LANGUAGE_ID . "&" . $tabControl->ActiveTabParam());
                }
            }
        }
        $DB->PrepareFields("b_form_field");
    }
}
$rsField = CFormField::GetByID($ID);
if (!$rsField || !$rsField->ExtractFields()) {
    $ID = 0;
    $str_ACTIVE = "Y";
    $str_C_SORT = CFormField::GetNextSort($WEB_FORM_ID);
    $str_TITLE_TYPE = "text";
    $str_IN_RESULTS_TABLE = "Y";
    $str_IN_EXCEL_TABLE = "Y";
} else {
    ####### get validators list
    $arCurrentValidators = array();
    if ($additional != "Y") {
        if ($ID > 0) {
            $rsCurrentValidators = CFormValidator::GetList($ID, array(), $by = "C_SORT", $order = "ASC");
            while ($arValidator = $rsCurrentValidators->Fetch()) {
                $arCurrentValidators[] = $arValidator;
            }
        }
    }
    #############################