Documentation

GetByID

CIBlockResult
CIBlockElement::GetByID(
 int ID
);

Returns the element parameters.

Parameters

ParameterDescription
ID Element ID.

Return Values

Return an instance of CIBlockResult with the information block element fields.

Remarks

The method does not check for the published state of the element or whether the element is the history record. To retrieve published elements only, use the method GetList().

See Also

  • CDBResult
  • CIBlockResult
  • Information block element fields
  • CIBlockElement::GetList()

    Example


    <?
    $res = CIBlockElement::GetByID($_GET["PID"]);
    if ($ar_res = $res->GetNext())
        echo $ar_res['NAME'];
    ?>
  • © «Bitrix24», 2001-2024
    Up