abstract class Contentstack

Contentstack abstract class to provide access to Stack Object

Methods

static Stack
Stack(string $api_key = '', string $access_token = '', string $environment = '', array $config = array('region' => '', 'branch' => '', 'live_preview' => array('enable' => false, 'host' => 'api.contentstack.io')))

Static method for the Stack constructor

static string
renderContent(string $content, Option $option)

No description

static array
renderContents(array $contents, Option $option)

No description

static string
jsonToHtml(object $content, Option $option)

No description

static array
jsonArrayToHtml(array $contents, Option $option)

No description

Details

at line 46
static Stack Stack(string $api_key = '', string $access_token = '', string $environment = '', array $config = array('region' => '', 'branch' => '', 'live_preview' => array('enable' => false, 'host' => 'api.contentstack.io')))

Static method for the Stack constructor

Parameters

string $api_key

: Contentstack Stack API KEY.

string $access_token

: Contentstack Stack ACCESS TOKEN.

string $environment

: Environment Name.

array $config

: Stack Configuration to provide region.

Return Value

Stack

at line 54
static string renderContent(string $content, Option $option)

No description

Parameters

string $content
Option $option

Return Value

string

at line 59
static array renderContents(array $contents, Option $option)

No description

Parameters

array $contents
Option $option

Return Value

array

at line 64
static string jsonToHtml(object $content, Option $option)

No description

Parameters

object $content
Option $option

Return Value

string

at line 69
static array jsonArrayToHtml(array $contents, Option $option)

No description

Parameters

array $contents
Option $option

Return Value

array