$city[] = array(
"MESSAGE" => "да",
"C_SORT" => 100,
"ACTIVE" => "Y",
"FIELD_TYPE" => "dropdown",
);
$fields = array(
"FORM_ID" => 4,
"ACTIVE" => Y,
"TITLE" => "Город",
"TITLE_TYPE" => "text",
"SID" => "city1",
"C_SORT" => 400,
"ADDITIONAL" => "N",
"REQUIRED" => "Y",
"IN_RESULTS_TABLE" => "Y",
"IN_EXCEL_TABLE" => "Y",
"FILTER_TITLE" => "Город",
"RESULTS_TABLE_TITLE" => "Город",
"arFILTER_ANSWER_TEXT" => array("dropdown"),
"arANSWER" => $city,
);
$NEW_ID = CFormField::Set($fields);
echo "<h1>!!".$NEW_ID."!!</h1>";
global $strError;
echo $strError; |