‪TYPO3CMS  ‪main
SysTemplateTreeBuilder.php
Go to the documentation of this file.
1 <?php
2 
3 declare(strict_types=1);
4 
5 /*
6  * This file is part of the TYPO3 CMS project.
7  *
8  * It is free software; you can redistribute it and/or modify it under
9  * the terms of the GNU General Public License, either version 2
10  * of the License, or any later version.
11  *
12  * For the full copyright and license information, please read the
13  * LICENSE.txt file that was distributed with this source code.
14  *
15  * The TYPO3 project - inspiring people to share!
16  */
17 
19 
26 use TYPO3\CMS\Core\Package\PackageManager;
43 
72 {
79  private array ‪$includedSysTemplateUids = [];
80 
82  private string ‪$type;
83 
85  private ?‪PhpFrontend ‪$cache = null;
86 
87  public function ‪__construct(
88  private readonly ‪ConnectionPool $connectionPool,
89  private readonly PackageManager $packageManager,
90  private readonly ‪Context $context,
91  private readonly ‪TreeFromLineStreamBuilder $treeFromTokenStreamBuilder,
92  ) {}
93 
98  string ‪$type,
99  array $sysTemplateRows,
101  ?‪SiteInterface $site = null,
103  ): ‪RootInclude {
104  if (!in_array(‪$type, ['constants', 'setup'], true)) {
105  throw new \RuntimeException('type must be either constants or setup', 1653737656);
106  }
107  $this->tokenizer = ‪$tokenizer;
108  $this->cache = ‪$cache;
109  $this->type = ‪$type;
110  $this->includedSysTemplateUids = [];
111 
112  $rootNode = new ‪RootInclude();
113  if (empty($sysTemplateRows)) {
114  return $rootNode;
115  }
116 
117  // Convenience code: Usually, at least one sys_template records needs to have 'clear' set. This resets
118  // the AST and triggers inclusion of "globals" TypoScript. When integrators missed to set the clear flags,
119  // important globals TypoScript is not loaded, leading to pretty hard to find issues in Frontend
120  // rendering. Since the details of the 'clear' flags are rather complex anyway, this code scans the given
121  // sys_template records if the flag is set somewhere and if not, actively sets it dynamically for the
122  // first templates. As a result, integrators do not need to think about the 'clear' flags at all for
123  // simple instances, it 'just works'.
124  $atLeastOneSysTemplateRowHasClearFlag = false;
125  foreach ($sysTemplateRows as $sysTemplateRow) {
126  if (($this->type === 'constants' && $sysTemplateRow['clear'] & 1) || ($this->type === 'setup' && $sysTemplateRow['clear'] & 2)) {
127  $atLeastOneSysTemplateRowHasClearFlag = true;
128  }
129  }
130  if (!$atLeastOneSysTemplateRowHasClearFlag) {
131  $firstRow = reset($sysTemplateRows);
132  $firstRow['clear'] = $this->type === 'constants' ? 1 : 2;
133  $sysTemplateRows[array_key_first($sysTemplateRows)] = $firstRow;
134  }
135 
136  foreach ($sysTemplateRows as $sysTemplateRow) {
137  $cacheIdentifier = 'sys-template-' . $this->type . '-' . $this->‪getSysTemplateRowIdentifier($sysTemplateRow, $site);
138  if ($this->cache) {
139  // Get from cache if possible
140  $includeNode = $this->cache->require($cacheIdentifier);
141  if ($includeNode) {
142  $rootNode->addChild($includeNode);
143  continue;
144  }
145  }
146  $includeNode = new ‪SysTemplateInclude();
147  $name = '[sys_template:' . $sysTemplateRow['uid'] . '] ' . $sysTemplateRow['title'];
148  $includeNode->setName($name);
149  $includeNode->setPid((int)$sysTemplateRow['pid']);
150  if ($this->type === 'constants') {
151  $includeNode->setLineStream($this->tokenizer->tokenize($sysTemplateRow['constants'] ?? ''));
152  } else {
153  $includeNode->setLineStream($this->tokenizer->tokenize($sysTemplateRow['config'] ?? ''));
154  }
155  if ($sysTemplateRow['root']) {
156  $includeNode->setRoot(true);
157  }
158  $clear = $sysTemplateRow['clear'];
159  if (($this->type === 'constants' && $clear & 1) || ($this->type === 'setup' && $clear & 2)) {
160  $includeNode->setClear(true);
161  }
162  $this->‪handleSysTemplateRecordInclude($includeNode, $sysTemplateRow, $site);
163  $this->treeFromTokenStreamBuilder->buildTree($includeNode, $this->type, $this->tokenizer);
164  $this->cache?->set($cacheIdentifier, $this->‪prepareNodeForCache($includeNode));
165  $rootNode->addChild($includeNode);
166  }
167 
168  return $rootNode;
169  }
170 
174  private function ‪handleSysTemplateRecordInclude(‪IncludeInterface $parentNode, array $row, ?‪SiteInterface $site): void
175  {
176  $this->includedSysTemplateUids[] = (int)$row['uid'];
177 
178  $isRoot = (bool)$row['root'];
179  $clearConstants = (int)$row['clear'] & 1;
180  $clearSetup = (int)$row['clear'] & 2;
181  $staticFileMode = (int)($row['static_file_mode']);
182  $includeStaticAfterBasedOn = (bool)$row['includeStaticAfterBasedOn'];
183 
184  if ($this->type === 'constants' && $clearConstants) {
185  $this->‪addDefaultTypoScriptFromGlobals($parentNode);
186  $this->‪addDefaultTypoScriptConstantsFromSite($parentNode, $site);
187  }
188  if ($this->type === 'setup' && $clearSetup) {
189  $this->‪addDefaultTypoScriptFromGlobals($parentNode);
190  }
191  if ($staticFileMode === 3 && $isRoot) {
192  $this->‪addExtensionStatics($parentNode);
193  }
194  if (!$includeStaticAfterBasedOn) {
195  $this->‪handleIncludeStaticFileArray($parentNode, (string)$row['include_static_file']);
196  }
197  if (!empty($row['basedOn'])) {
198  $this->‪handleIncludeBasedOnTemplates($parentNode, (string)$row['basedOn'], $site);
199  }
200  if ($includeStaticAfterBasedOn) {
201  $this->‪handleIncludeStaticFileArray($parentNode, (string)$row['include_static_file']);
202  }
203  if ($staticFileMode === 1 || ($staticFileMode === 0 && $isRoot)) {
204  $this->‪addExtensionStatics($parentNode);
205  }
206  }
207 
221  private function ‪handleIncludeStaticFileArray(‪IncludeInterface $parentNode, string $includeStaticFileString): void
222  {
223  $includeStaticFileIncludeArray = ‪GeneralUtility::trimExplode(',', $includeStaticFileString, true);
224  foreach ($includeStaticFileIncludeArray as $includeStaticFile) {
225  $cacheIdentifier = preg_replace('/[^[:alnum:]]/u', '-', mb_strtolower($includeStaticFile)) . '-' . ‪$this->type;
226  if ($this->cache) {
227  $node = $this->cache->require($cacheIdentifier);
228  if ($node) {
229  $parentNode->‪addChild($node);
230  continue;
231  }
232  }
234  $node->setName($includeStaticFile);
235  $this->‪handleSingleIncludeStaticFile($node, $includeStaticFile);
236  $this->cache?->set($cacheIdentifier, $this->‪prepareNodeForCache($node));
237  $parentNode->‪addChild($node);
238  }
239  }
240 
246  private function ‪handleIncludeBasedOnTemplates(‪IncludeInterface $parentNode, string $basedOnList, ?‪SiteInterface $site): void
247  {
248  $basedOnTemplateUids = ‪GeneralUtility::intExplode(',', $basedOnList, true);
249  // Filter uids that have been handled already.
250  $basedOnTemplateUids = array_diff($basedOnTemplateUids, $this->includedSysTemplateUids);
251  if (empty($basedOnTemplateUids)) {
252  return;
253  }
254 
255  $basedOnTemplateRows = $this->‪getBasedOnSysTemplateRowsFromDatabase($basedOnTemplateUids);
256 
257  foreach ($basedOnTemplateUids as $basedOnTemplateUid) {
258  if (is_array($basedOnTemplateRows[$basedOnTemplateUid] ?? false)) {
259  $sysTemplateRow = $basedOnTemplateRows[$basedOnTemplateUid];
260  $this->includedSysTemplateUids[] = (int)$sysTemplateRow['uid'];
261  $includeNode = new ‪SysTemplateInclude();
262  $name = '[sys_template:' . $sysTemplateRow['uid'] . '] ' . $sysTemplateRow['title'];
263  $includeNode->setName($name);
264  $includeNode->setPid((int)$sysTemplateRow['pid']);
265  if ($this->type === 'constants') {
266  $includeNode->setLineStream($this->tokenizer->tokenize($sysTemplateRow['constants'] ?? ''));
267  } else {
268  $includeNode->setLineStream($this->tokenizer->tokenize($sysTemplateRow['config'] ?? ''));
269  }
270  $this->treeFromTokenStreamBuilder->buildTree($includeNode, $this->type, $this->tokenizer);
271  if ($sysTemplateRow['root']) {
272  $includeNode->setRoot(true);
273  }
274  $clear = $sysTemplateRow['clear'];
275  if (($this->type === 'constants' && $clear & 1)
276  || ($this->type === 'setup' && $clear & 2)
277  ) {
278  $includeNode->setClear(true);
279  }
280  $parentNode->‪addChild($includeNode);
281  $this->‪handleSysTemplateRecordInclude($includeNode, $sysTemplateRow, $site);
282  }
283  }
284  }
285 
294  private function ‪handleSingleIncludeStaticFile(‪IncludeInterface $parentNode, $includeStaticFileString): void
295  {
296  if (!‪PathUtility::isExtensionPath($includeStaticFileString)) {
297  // Must start with 'EXT:'
298  throw new \RuntimeException(
299  'Single include_static_file does not start with "EXT:": ' . $includeStaticFileString,
300  1651137904
301  );
302  }
303 
304  // Cut off 'EXT:'
305  $includeStaticFileWithoutExt = substr($includeStaticFileString, 4);
306  $includeStaticFileExtKeyAndPath = ‪GeneralUtility::trimExplode('/', $includeStaticFileWithoutExt, true, 2);
307  if (empty($includeStaticFileExtKeyAndPath[0]) || empty($includeStaticFileExtKeyAndPath[1])) {
308  throw new \RuntimeException(
309  'Syntax of static includes is "EXT:extension_key/Path". Usually enforced as such by ExtensionManagementUtility::addStaticFile',
310  1651138603
311  );
312  }
313  $extensionKey = $includeStaticFileExtKeyAndPath[0];
314  if (!‪ExtensionManagementUtility::isLoaded($extensionKey)) {
315  return;
316  }
317  // example: '/.../my_extension/Configuration/TypoScript/MyStaticInclude/'
318  $pathSegmentWithAppendedSlash = rtrim($includeStaticFileExtKeyAndPath[1]) . '/';
319  $path = ‪ExtensionManagementUtility::extPath($extensionKey, $pathSegmentWithAppendedSlash);
320 
321  // '/.../my_extension/Configuration/TypoScript/MyStaticInclude/include_static_file.txt'
322  $includeStaticFileFileIncludePath = $path . 'include_static_file.txt';
323  if (file_exists($path . 'include_static_file.txt')) {
324  $includeStaticFileFileInclude = new ‪IncludeStaticFileFileInclude();
325  $name = 'EXT:' . $extensionKey . '/' . $pathSegmentWithAppendedSlash . 'include_static_file.txt';
326  $includeStaticFileFileInclude->setName($name);
327  $includeStaticFileFileInclude->setPath($includeStaticFileString);
328  $parentNode->‪addChild($includeStaticFileFileInclude);
329  $includeStaticFileFileIncludeContent = (string)file_get_contents($includeStaticFileFileIncludePath);
330  // @todo: There is no array_unique() for DB based include_static_file content?!
331  $includeStaticFileFileIncludeArray = array_unique(‪GeneralUtility::trimExplode(',', $includeStaticFileFileIncludeContent, true));
332  foreach ($includeStaticFileFileIncludeArray as $includeStaticFileFileIncludeString) {
333  $this->‪handleSingleIncludeStaticFile($includeStaticFileFileInclude, $includeStaticFileFileIncludeString);
334  }
335  }
336 
337  $extensions = ['.typoscript', '.ts', '.txt'];
338  foreach ($extensions as $extension) {
339  // '/.../my_extension/Configuration/TypoScript/MyStaticInclude/[constants|setup]' plus one of the allowed extensions like '.typoscript'
340  $fileName = $path . $this->type . $extension;
341  if (file_exists($fileName)) {
342  $fileContent = file_get_contents($fileName);
343  $fileNode = new ‪FileInclude();
344  $name = 'EXT:' . $extensionKey . '/' . $pathSegmentWithAppendedSlash . $this->type . $extension;
345  $fileNode->setName($name);
346  $fileNode->setPath($name);
347  $fileNode->setLineStream($this->tokenizer->tokenize($fileContent));
348  $this->treeFromTokenStreamBuilder->buildTree($fileNode, $this->type, $this->tokenizer);
349  $parentNode->‪addChild($fileNode);
350  }
351  }
352 
353  $extensionKeyWithoutUnderscores = str_replace('_', '', $extensionKey);
354  $this->‪addStaticMagicFromGlobals($parentNode, $extensionKeyWithoutUnderscores . '/' . $pathSegmentWithAppendedSlash);
355  }
356 
361  private function ‪addExtensionStatics(‪IncludeInterface $parentNode): void
362  {
363  foreach ($this->packageManager->getActivePackages() as $package) {
364  $extensionKey = $package->getPackageKey();
365  $extensionKeyWithoutUnderscores = str_replace('_', '', $extensionKey);
366  $file = $package->getPackagePath() . 'ext_typoscript_' . $this->type . '.typoscript';
367  if (file_exists($file)) {
368  ‪$identifier = preg_replace('/[^[:alnum:]]/u', '-', 'ext-' . $extensionKey . '-ext-typoscript-' . $this->type . '-typoscript');
369  if ($this->cache) {
370  $node = $this->cache->require(‪$identifier);
371  if ($node) {
372  $parentNode->‪addChild($node);
373  continue;
374  }
375  }
376  $fileContent = file_get_contents($file);
377  $this->‪addStaticMagicFromGlobals($parentNode, $extensionKeyWithoutUnderscores);
378  $node = new ‪ExtensionStaticInclude();
379  $node->setName('EXT:' . $extensionKey . '/ext_typoscript_' . $this->type . '.typoscript');
380  $node->setPath('EXT:' . $extensionKey . '/ext_typoscript_' . $this->type . '.typoscript');
381  $node->setLineStream($this->tokenizer->tokenize($fileContent));
382  $this->treeFromTokenStreamBuilder->buildTree($node, $this->type, $this->tokenizer);
383  $this->cache?->set(‪$identifier, $this->‪prepareNodeForCache($node));
384  $parentNode->‪addChild($node);
385  }
386  }
387  }
388 
393  private function ‪addDefaultTypoScriptFromGlobals(‪IncludeInterface $parentConstantNode): void
394  {
395  $defaultTypoScriptConstants = ‪$GLOBALS['TYPO3_CONF_VARS']['FE']['defaultTypoScript_' . ‪$this->type] ?? '';
396  if (!empty($defaultTypoScriptConstants)) {
397  $cacheIdentifier = 'globals-defaulttyposcript-' . $this->type . '-' . hash('xxh3', $defaultTypoScriptConstants);
398  if ($this->cache) {
399  $node = $this->cache->require($cacheIdentifier);
400  if ($node) {
401  $parentConstantNode->‪addChild($node);
402  return;
403  }
404  }
405  $node = new ‪DefaultTypoScriptInclude();
406  $node->setName('TYPO3_CONF_VARS[\'FE\'][\'defaultTypoScript_' . $this->type . '\']');
407  $node->setLineStream($this->tokenizer->tokenize($defaultTypoScriptConstants));
408  $this->treeFromTokenStreamBuilder->buildTree($node, $this->type, $this->tokenizer);
409  $this->cache?->set($cacheIdentifier, $this->prepareNodeForCache($node));
410  $parentConstantNode->addChild($node);
411  }
412  }
413 
417  private function addDefaultTypoScriptConstantsFromSite(IncludeInterface $parentConstantNode, ?SiteInterface $site): void
418  {
419  if (!$site instanceof Site) {
420  return;
421  }
422  $siteConstants = '';
423  $siteSettings = $site->getSettings();
424  if ($siteSettings->isEmpty()) {
425  return;
426  }
427  $cacheIdentifier = 'site-constants-' . hash('xxh3', json_encode($siteSettings, JSON_THROW_ON_ERROR));
428  if ($this->cache) {
429  $node = $this->cache->require($cacheIdentifier);
430  if ($node) {
431  $parentConstantNode->addChild($node);
432  return;
433  }
434  }
435  $siteSettings = $siteSettings->getAllFlat();
436  foreach ($siteSettings as $nodeIdentifier => $value) {
437  $siteConstants .= $nodeIdentifier . ' = ' . $value . LF;
438  }
439  $node = new SiteInclude();
440  $node->setName('‪Site constants settings of site "' . $site->getIdentifier() . '"');
441  $node->setLineStream($this->tokenizer->tokenize($siteConstants));
442  $this->cache?->set($cacheIdentifier, $this->prepareNodeForCache($node));
443  $parentConstantNode->addChild($node);
444  }
445 
450  private function addStaticMagicFromGlobals(IncludeInterface $parentNode, string $identifier): void
451  {
452  // defaultTypoScript_constants.' or defaultTypoScript_setup.'
453  $source = $GLOBALS['TYPO3_CONF_VARS']['FE']['defaultTypoScript_' . $this->type . '.'][$identifier] ?? null;
454  if (!empty($source)) {
455  $node = new DefaultTypoScriptMagicKeyInclude();
456  $node->setName('TYPO3_CONF_VARS globals_defaultTypoScript_' . $this->type . '.' . $identifier);
457  $node->setLineStream($this->tokenizer->tokenize($source));
458  $this->treeFromTokenStreamBuilder->buildTree($node, $this->type, $this->tokenizer);
459  $parentNode->addChild($node);
460  }
461  // If this is a template of type "default content rendering", see if other extensions have added their TypoScript that should be included.
462  if (in_array($identifier, $GLOBALS['TYPO3_CONF_VARS']['FE']['contentRenderingTemplates'], true)) {
463  $source = $GLOBALS['TYPO3_CONF_VARS']['FE']['defaultTypoScript_' . $this->type . '.']['defaultContentRendering'] ?? null;
464  if (!empty($source)) {
465  $node = new DefaultTypoScriptMagicKeyInclude();
466  $node->setName('TYPO3_CONF_VARS defaultContentRendering ' . $this->type . ' for ' . $identifier);
467  $node->setLineStream($this->tokenizer->tokenize($source));
468  $this->treeFromTokenStreamBuilder->buildTree($node, $this->type, $this->tokenizer);
469  $parentNode->addChild($node);
470  }
471  }
472  }
473 
480  private function getBasedOnSysTemplateRowsFromDatabase(array $basedOnTemplateUids): array
481  {
482  $queryBuilder = $this->connectionPool->getQueryBuilderForTable('sys_template');
483  $queryBuilder->setRestrictions($this->getSysTemplateQueryRestrictionContainer());
484  $basedOnTemplateRows = $queryBuilder
485  ->select('*')
486  ->from('sys_template')
487  ->where(
488  $queryBuilder->expr()->in(
489  'uid',
490  $queryBuilder->createNamedParameter($basedOnTemplateUids, Connection::PARAM_INT_ARRAY)
491  )
492  )
493  ->executeQuery()
494  ->fetchAllAssociative();
495  return array_combine(array_column($basedOnTemplateRows, 'uid'), $basedOnTemplateRows);
496  }
497 
512  private function getSysTemplateRowIdentifier(array $sysTemplateRow, ?SiteInterface $site): string
513  {
514  $siteIdentifier = 'dummy';
515  if ($this->type === 'constants' && ((int)$sysTemplateRow['clear'] & 1) && $site !== null) {
516  $siteIdentifier = $site->getIdentifier();
517  }
518  $cacheRelevantSysTemplateRowValues = [
519  'root' => (int)$sysTemplateRow['root'],
520  'clear' => (int)$sysTemplateRow['clear'],
521  'include_static_file' => (string)$sysTemplateRow['include_static_file'],
522  'constants' => (string)$sysTemplateRow['constants'],
523  'config' => (string)$sysTemplateRow['config'],
524  'basedOn' => (string)$sysTemplateRow['basedOn'],
525  'includeStaticAfterBasedOn' => (int)$sysTemplateRow['includeStaticAfterBasedOn'],
526  'static_file_mode' => (int)$sysTemplateRow['static_file_mode'],
527  'siteIdentifier' => $siteIdentifier,
528  ];
529  return hash('xxh3', json_encode($cacheRelevantSysTemplateRowValues, JSON_THROW_ON_ERROR));
530  }
531 
532  private function prepareNodeForCache(IncludeInterface $node): string
533  {
534  return 'return unserialize(\'' . addcslashes(serialize($node), '\'\\') . '\');';
535  }
536 
542  {
543  $restrictionContainer = GeneralUtility::makeInstance(DefaultRestrictionContainer::class);
544  if ($this->context->getPropertyFromAspect('visibility', 'includeHiddenContent', false)) {
545  $restrictionContainer->removeByType(HiddenRestriction::class);
546  }
547  return $restrictionContainer;
548  }
549 }
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\IncludeStaticFileFileInclude
Definition: IncludeStaticFileFileInclude.php:26
‪TYPO3\CMS\Core\Database\Query\Restriction\HiddenRestriction
Definition: HiddenRestriction.php:27
‪TYPO3\CMS\Core\Site\Entity\SiteInterface
Definition: SiteInterface.php:26
‪TYPO3\CMS\Core\Utility\PathUtility\isExtensionPath
‪static isExtensionPath(string $path)
Definition: PathUtility.php:117
‪TYPO3\CMS\Core\Utility\PathUtility
Definition: PathUtility.php:27
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\$cache
‪PhpFrontend $cache
Definition: SysTemplateTreeBuilder.php:85
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\$type
‪string $type
Definition: SysTemplateTreeBuilder.php:82
‪TYPO3\CMS\Core\TypoScript\IncludeTree
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\__construct
‪__construct(private readonly ConnectionPool $connectionPool, private readonly PackageManager $packageManager, private readonly Context $context, private readonly TreeFromLineStreamBuilder $treeFromTokenStreamBuilder,)
Definition: SysTemplateTreeBuilder.php:87
‪TYPO3\CMS\Core\Cache\Frontend\PhpFrontend
Definition: PhpFrontend.php:25
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\ExtensionStaticInclude
Definition: ExtensionStaticInclude.php:26
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\IncludeInterface\addChild
‪addChild(IncludeInterface $node)
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\addExtensionStatics
‪addExtensionStatics(IncludeInterface $parentNode)
Definition: SysTemplateTreeBuilder.php:361
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\prepareNodeForCache
‪prepareNodeForCache(IncludeInterface $node)
Definition: SysTemplateTreeBuilder.php:532
‪TYPO3\CMS\Core\TypoScript\IncludeTree\TreeFromLineStreamBuilder
Definition: TreeFromLineStreamBuilder.php:58
‪TYPO3\CMS\Core\Context\Context
Definition: Context.php:54
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\handleSysTemplateRecordInclude
‪handleSysTemplateRecordInclude(IncludeInterface $parentNode, array $row, ?SiteInterface $site)
Definition: SysTemplateTreeBuilder.php:174
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\addDefaultTypoScriptFromGlobals
‪addDefaultTypoScriptFromGlobals(IncludeInterface $parentConstantNode)
Definition: SysTemplateTreeBuilder.php:393
‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility\isLoaded
‪static isLoaded(string $key)
Definition: ExtensionManagementUtility.php:55
‪TYPO3\CMS\Core\Site\Entity\Site
Definition: Site.php:42
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\handleIncludeBasedOnTemplates
‪handleIncludeBasedOnTemplates(IncludeInterface $parentNode, string $basedOnList, ?SiteInterface $site)
Definition: SysTemplateTreeBuilder.php:246
‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility
Definition: ExtensionManagementUtility.php:32
‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility\extPath
‪static extPath(string $key, string $script='')
Definition: ExtensionManagementUtility.php:82
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\SiteInclude
Definition: SiteInclude.php:25
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\IncludeInterface
Definition: IncludeInterface.php:39
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\handleIncludeStaticFileArray
‪handleIncludeStaticFileArray(IncludeInterface $parentNode, string $includeStaticFileString)
Definition: SysTemplateTreeBuilder.php:221
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\FileInclude
Definition: FileInclude.php:28
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\handleSingleIncludeStaticFile
‪handleSingleIncludeStaticFile(IncludeInterface $parentNode, $includeStaticFileString)
Definition: SysTemplateTreeBuilder.php:294
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\getTreeBySysTemplateRowsAndSite
‪getTreeBySysTemplateRowsAndSite(string $type, array $sysTemplateRows, TokenizerInterface $tokenizer, ?SiteInterface $site=null, PhpFrontend $cache=null)
Definition: SysTemplateTreeBuilder.php:97
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\IncludeStaticFileDatabaseInclude
Definition: IncludeStaticFileDatabaseInclude.php:27
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\getSysTemplateRowIdentifier
‪getSysTemplateRowIdentifier(array $sysTemplateRow, ?SiteInterface $site)
Definition: SysTemplateTreeBuilder.php:512
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\$tokenizer
‪TokenizerInterface $tokenizer
Definition: SysTemplateTreeBuilder.php:84
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\DefaultTypoScriptMagicKeyInclude
Definition: DefaultTypoScriptMagicKeyInclude.php:26
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\addDefaultTypoScriptConstantsFromSite
‪addDefaultTypoScriptConstantsFromSite(IncludeInterface $parentConstantNode, ?SiteInterface $site)
Definition: SysTemplateTreeBuilder.php:417
‪TYPO3\CMS\Core\Database\Connection
Definition: Connection.php:41
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\$includedSysTemplateUids
‪array $includedSysTemplateUids
Definition: SysTemplateTreeBuilder.php:79
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\getBasedOnSysTemplateRowsFromDatabase
‪getBasedOnSysTemplateRowsFromDatabase(array $basedOnTemplateUids)
Definition: SysTemplateTreeBuilder.php:480
‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:25
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\DefaultTypoScriptInclude
Definition: DefaultTypoScriptInclude.php:26
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\RootInclude
Definition: RootInclude.php:27
‪TYPO3\CMS\Core\Database\ConnectionPool
Definition: ConnectionPool.php:46
‪TYPO3\CMS\Core\TypoScript\Tokenizer\TokenizerInterface
Definition: TokenizerInterface.php:40
‪TYPO3\CMS\Core\Utility\GeneralUtility
Definition: GeneralUtility.php:52
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\getSysTemplateQueryRestrictionContainer
‪getSysTemplateQueryRestrictionContainer()
Definition: SysTemplateTreeBuilder.php:541
‪TYPO3\CMS\Core\Utility\GeneralUtility\intExplode
‪static list< int > intExplode(string $delimiter, string $string, bool $removeEmptyValues=false)
Definition: GeneralUtility.php:751
‪TYPO3\CMS\Core\TypoScript\IncludeTree\IncludeNode\SysTemplateInclude
Definition: SysTemplateInclude.php:26
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder
Definition: SysTemplateTreeBuilder.php:72
‪TYPO3\CMS\Core\TypoScript\IncludeTree\SysTemplateTreeBuilder\addStaticMagicFromGlobals
‪addStaticMagicFromGlobals(IncludeInterface $parentNode, string $identifier)
Definition: SysTemplateTreeBuilder.php:450
‪TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode
‪static list< string > trimExplode(string $delim, string $string, bool $removeEmptyValues=false, int $limit=0)
Definition: GeneralUtility.php:817
‪TYPO3\CMS\Webhooks\Message\$identifier
‪identifier readonly string $identifier
Definition: FileAddedMessage.php:37
‪TYPO3\CMS\Core\Database\Query\Restriction\DefaultRestrictionContainer
Definition: DefaultRestrictionContainer.php:24