BackendConfigurationManager

Read onlyYes
FinalYes

Load TypoScript of a page in backend mode.

Extbase Backend modules can be configured with Frontend TypoScript. This is of course a very bad thing, but it is how it is ^^ (we'll get rid of this at some point, promised!)

First, this means Backend extbase module performance scales with the amount of Frontend TypoScript. Furthermore, in contrast to Frontend, Backend Modules are not necessarily bound to pages in the first place - they may not have a page tree und thus no page id at all, like for instance the ext:beuser module.

Unfortunately, extbase still has to calculate some TypoScript in any case, even if there is no page id at all: The default configuration of extbase Backend modules is the "module." TypoScript setup top-level key. The base config of this is delivered by extbase extensions that have Backend Modules using ext_typoscript_setup.typoscript, and/or via TYPO3_CONF_VARS TypoScript setup defaults. Those have to be loaded in any case, even if there is no page at all in the page tree.

The code thus has to hop through quite some loops to "find" some relevant page id it can guess if none is incoming from the request. It even fakes a default sys_template row to trigger TypoScript loading of globals and ext_typoscript_setup.typoscript if it couldn't find anything.

Internal

only to be used within Extbase, not part of TYPO3 Core API.

Table of Contents

Methods

__construct()  : mixed
getConfiguration()  : array<string|int, mixed>
Loads the Extbase Framework configuration.
getTypoScriptSetup()  : array<string|int, mixed>
Returns TypoScript Setup array from current Environment.

Methods

__construct()

public __construct(TypoScriptService $typoScriptService, PhpFrontend $typoScriptCache, FrontendInterface $runtimeCache, SysTemplateRepository $sysTemplateRepository, SiteFinder $siteFinder, FrontendTypoScriptFactory $frontendTypoScriptFactory, ConnectionPool $connectionPool, SetRegistry $setRegistry) : mixed
Parameters
$typoScriptService : TypoScriptService
$typoScriptCache : PhpFrontend
$runtimeCache : FrontendInterface
$sysTemplateRepository : SysTemplateRepository
$siteFinder : SiteFinder
$frontendTypoScriptFactory : FrontendTypoScriptFactory
$connectionPool : ConnectionPool
$setRegistry : SetRegistry

getConfiguration()

Loads the Extbase Framework configuration.

public getConfiguration(ServerRequestInterface $request, array<string|int, mixed> $configuration[, string|null $extensionName = null ][, string|null $pluginName = null ]) : array<string|int, mixed>

The Extbase framework configuration HAS TO be retrieved using this method, as they are come from different places than the normal settings. Framework configuration is, in contrast to normal settings, needed for the Extbase framework to operate correctly.

Parameters
$request : ServerRequestInterface
$configuration : array<string|int, mixed>

low level configuration from outside, typically ContentObjectRenderer TypoScript element config

$extensionName : string|null = null

if specified, the configuration for the given extension will be returned (plugin.tx_extensionname)

$pluginName : string|null = null

if specified, the configuration for the given plugin will be returned (plugin.tx_extensionname_pluginname)

Return values
array<string|int, mixed>

the Extbase framework configuration

getTypoScriptSetup()

Returns TypoScript Setup array from current Environment.

public getTypoScriptSetup(ServerRequestInterface $request) : array<string|int, mixed>
Parameters
$request : ServerRequestInterface
Return values
array<string|int, mixed>

the raw TypoScript setup


        
On this page

Search results