Bitrix Site Manager

CAdminListRow::AddSelectField

void
CAdminListRow::AddSelectField(
  string $ID, 
  array $arValues[, 
  array $arAttributes = array()]
)

The AddSelectField method adds a drop-down list field. The field is active in the editing mode only.

Parameters

Parameter Description
ID The cell identifier.
arValues An array of drop-down list items in the format of "value" => "name".
arAttributes An array of additional SELECT tag attributes in the format: "attribute" => "value".

Example


$arStatusList = array(
    "Draft" => GetMessage("STATUS_DRAFT"),
    "Published" => GetMessage("STATUS_PUBLISHED"),
);

$row->AddSelectField(
    "STATUS", 
    $arStatusList
);