Documentation

landing.template.setLandingRef

landing.template.setLandingRef(id, data)

The method sets included sections for a page within a specific template (the page must be binded to the template via TPL_ID field). Returns true on success and error otherwise.

Parameters

Parameter Description
id Landing page ID.
data Array of data for set up (if the array is empty or not passed, the set sections will reset). The array keys are section IDs and values - are IDs of pages to be set as the section.

Example

BX24.callMethod(
   'landing.template.setLandingRef',
   {
      id: 557,
      data: {
         1: 614,
         2: 615,
         3: 616
      }
   },
   function(result)
   {
      if(result.error())
      {
         console.error(result.error());
      }
      else
      {
         console.info(result.data());
      }
   }
);


© «Bitrix24», 2001-2024
Up