Documentation

Operation principles

Connecting at PHP page

\CJSCore::init("sidepanel");

Using in JavaScript

All JavaScript-classes for slider are located in the BX.SidePanel namespace. To access the slider API, BX.SidePanel.Instance singleton object is used.

BX.SidePanel.Instance.open("/mypage.php"); //Open mypage.php page in the slider

Operation principle

Slider - it is a side panel, which can open site landing pages in the iframe, as well as display arbitrary content inside. Applying the iframe allows to use off-the-shelf components that operate on common site pages.

Slider expands from right to the left, occupying all space from top to bottom. Page scrolling is disabled for the correct interface operation and the padding-right is added (equal to the width of disabled scroll) for all contents.

Loader is displayed when the slider is opened; loader dissapears as soon as the side panel content is loaded. Slider is not eliminated after closure. If the slider is opened again, it will appear immediately with the same content. Caching of closed slider can be cancelled by the cacheable=false option.

Another slider can be opened from slider. In this case, new slider will appear over the previous one. Corresponding events occur during the complete slider operation cycle (opening, loading, closing, deleting). These events are generated both in parent window, as well as in the iframe.

Opening of the slider occurs via two methods:



© «Bitrix24», 2001-2024