Documentation

GetByID

Description and parameters

array
CCatalog::GetByID(
 int ID
);

Returns array with catalog parameters, including some parameters related to iblock. If the iblock with $ID does not exist or is not a catalog, returns false. Non-static method.

Call parameters

ParameterDescription
ID Catalog - iblock code.

Returned values

If the iblock with $ID does not exist or is not a catalog, returns false. Otherwise returns an associative array with keys:

Key Description
IBLOCK_ID Code (ID) for iblock.
ID Code (ID) for iblock.
IBLOCK_TYPE_ID Iblock type.
LID Iblock site code.
NAME Iblock name.
SUBSCRIPTION Flag "Selling content" (Y/N).
VAT_ID VA type code (ID).
PRODUCT_IBLOCK_ID Product iblock code (ID) (for SKU iblock). For simple catalog contains 0.
SKU_PROPERTY_ID Binding property (ID) for product iblock (for SKU iblock). For simple catalog contains 0.
OFFERS_IBLOCK_ID SKU iblock (ID) (for situation when both product iblock and SKU iblock serve as commercial catalog). In all the rest of cases, contains NULL. This key is used for compatibility and the method CCatalog::GetByIDExt() is recommended for getting full details on the "product iblock - SKU iblock" binding.
OFFERS_PROPERTY_ID Code (ID) for SKU to products binding property, when product iblock and SKU iblock serve as commercial catalog). In all the rest of cases contains NULL. Key is used for compatibility. The method CCatalog::GetByIDExt() is recommended for getting full details on the "product iblock - SKU iblock" binding.
OFFERS Flag for available SKU iblock (Y/N).

See Also


© «Bitrix24», 2001-2024
Up