Documentation

Iblock::getElementUrl

Attention! We strongly recommend first to learn more about Sites module REST documentation to understand how the module functions (with REST available in Bitrix24 Self-hosted editions). View this documentation as useful source when working with Bitrix24 Self-hosted editions and find out more details about API and only REST is not enough.

public static function Iblock::getElementUrl(
   $siteId, 
   $elementId
);

Returns product URL within site. Applicable to online store only.

Parameters

ParameterDescriptionVersion
siteIdSite ID.
elementIdElement ID.

Example

$siteId = 571;
$elementId = 6697;

if (\Bitrix\Main\Loader::includeModule('landing'))
{
   $elementUrl = \Bitrix\Landing\Connector\Iblock::getElementUrl(
      $siteId, $elementId
   );
   echo $elementUrl;
}


© «Bitrix24», 2001-2024