Bitrix Site Manager

CFilterDictionary::Add

int
Add(
 array arFields 
);

The Add method adds a new dictionary with parameters specified in the arFields array.

Parameters

ParameterDescription
arFields An array of the format Array(field1=>value1[, field2=>value2 [, ..]]):
  • field - field name;
  • value - field value.
The fields are listed in the Dictionary table. The required fields must be present.

Return Values

The method returns the ID of the created record on success, or false otherwise.

See Also

Dictionary table fields

Example



<?
$arFields = Array(
	TITLE        - > $TITLE,
	TYPE      - > $TYPE,     
);

$ID = CFilterDictionary::Add($arFields);

if (IntVal($ID)<=0)
    echo "Error!";
?>