Documentation

landing.landing.add

Scope: landing Permissions to execute: for all

landing.landing.add(fields)

This method adds landing page. Returns created page ID or an error.

Parameters

Parameter Description Available from version
fields Entity fields

Example

BX24.callMethod(
	'landing.landing.add',
	{
		fields: {
			TITLE: 'My first page!',
			CODE: 'firstpage',
			SITE_ID: 205
		}
	},
	function(result)
	{
		if(result.error())
		{
			console.error(result.error());
		}
		else
		{
			console.info(result.data());
		}
	}
);

Please note, that when creating a landing page, a theme color code is also passed (THEME_CODE: 'wedding'). Its required for the page to match with the color scheme. If it is not done, the page will have the default theme.



© «Bitrix24», 2001-2024