‪TYPO3CMS  10.4
ext_localconf.php
Go to the documentation of this file.
1 <?php
2 
3 defined('TYPO3_MODE') or die();
4 
5 // Register all available content objects
6 ‪$GLOBALS['TYPO3_CONF_VARS']['FE']['ContentObjects'] = array_merge(‪$GLOBALS['TYPO3_CONF_VARS']['FE']['ContentObjects'], [
7  'TEXT' => \‪TYPO3\CMS\Frontend\ContentObject\TextContentObject::class,
8  'CASE' => \‪TYPO3\CMS\Frontend\ContentObject\CaseContentObject::class,
9  'COA' => \‪TYPO3\CMS\Frontend\ContentObject\ContentObjectArrayContentObject::class,
10  'COA_INT' => \‪TYPO3\CMS\Frontend\ContentObject\ContentObjectArrayInternalContentObject::class,
11  'USER' => \‪TYPO3\CMS\Frontend\ContentObject\UserContentObject::class,
12  'USER_INT' => \‪TYPO3\CMS\Frontend\ContentObject\UserInternalContentObject::class,
13  'FILES' => \‪TYPO3\CMS\Frontend\ContentObject\FilesContentObject::class,
14  'IMAGE' => \‪TYPO3\CMS\Frontend\ContentObject\ImageContentObject::class,
15  'IMG_RESOURCE' => \‪TYPO3\CMS\Frontend\ContentObject\ImageResourceContentObject::class,
16  'CONTENT' => \‪TYPO3\CMS\Frontend\ContentObject\ContentContentObject::class,
17  'RECORDS' => \‪TYPO3\CMS\Frontend\ContentObject\RecordsContentObject::class,
18  'HMENU' => \‪TYPO3\CMS\Frontend\ContentObject\HierarchicalMenuContentObject::class,
19  'LOAD_REGISTER' => \‪TYPO3\CMS\Frontend\ContentObject\LoadRegisterContentObject::class,
20  'RESTORE_REGISTER' => \‪TYPO3\CMS\Frontend\ContentObject\RestoreRegisterContentObject::class,
21  'TEMPLATE' => \‪TYPO3\CMS\Frontend\ContentObject\TemplateContentObject::class,
22  'FLUIDTEMPLATE' => \‪TYPO3\CMS\Frontend\ContentObject\FluidTemplateContentObject::class,
23  'SVG' => \‪TYPO3\CMS\Frontend\ContentObject\ScalableVectorGraphicsContentObject::class,
24  'EDITPANEL' => \‪TYPO3\CMS\Frontend\ContentObject\EditPanelContentObject::class
25 ]);
26 
27 // Register eID provider for showpic
28 ‪$GLOBALS['TYPO3_CONF_VARS']['FE']['eID_include']['tx_cms_showpic'] = \‪TYPO3\CMS\Frontend\Controller\ShowImageController::class . '::processRequest';
29 
30 \‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addUserTSConfig('
31  options.saveDocView = 1
32  options.saveDocNew = 1
33  options.saveDocNew.pages = 0
34  options.saveDocNew.sys_file = 0
35  options.saveDocNew.sys_file_metadata = 0
36  options.disableDelete.sys_file = 1
37 ');
38 
39 \‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTypoScriptSetup(
40  '
41 # Content selection
42 styles.content.get = CONTENT
43 styles.content.get {
44  table = tt_content
45  select {
46  orderBy = sorting
47  where = {#colPos}=0
48  }
49 }
50 
51 
52 # Content element rendering
53 tt_content = CASE
54 tt_content {
55  key {
56  field = CType
57  }
58  default = TEXT
59  default {
60  field = CType
61  htmlSpecialChars = 1
62  wrap = <p style="background-color: yellow; padding: 0.5em 1em;"><strong>ERROR:</strong> Content Element with uid "{field:uid}" and type "|" has no rendering definition!</p>
63  wrap.insertData = 1
64  }
65 }
66  '
67 );
68 
69 // Registering hooks for the tree list cache
70 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processDatamapClass'][] = \TYPO3\CMS\Frontend\Hooks\TreelistCacheUpdateHooks::class;
71 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processCmdmapClass'][] = \TYPO3\CMS\Frontend\Hooks\TreelistCacheUpdateHooks::class;
72 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['moveRecordClass'][] = \TYPO3\CMS\Frontend\Hooks\TreelistCacheUpdateHooks::class;
73 
74 // Register for hooks to show preview of tt_content elements in page module
75 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/class.tx_cms_layout.php']['tt_content_drawItem']['image'] =
76  \TYPO3\CMS\Frontend\Hooks\PageLayoutView\ImagePreviewRenderer::class;
77 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/class.tx_cms_layout.php']['tt_content_drawItem']['textpic'] =
78  \TYPO3\CMS\Frontend\Hooks\PageLayoutView\TextpicPreviewRenderer::class;
79 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/class.tx_cms_layout.php']['tt_content_drawItem']['text'] =
80  \TYPO3\CMS\Frontend\Hooks\PageLayoutView\TextPreviewRenderer::class;
81 $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/class.tx_cms_layout.php']['tt_content_drawItem']['textmedia'] =
82  \TYPO3\CMS\Frontend\Hooks\PageLayoutView\TextmediaPreviewRenderer::class;
83 
84 // Register search key shortcuts
85 $GLOBALS['TYPO3_CONF_VARS']['SYS']['livesearch']['content'] = 'tt_content';
86 
87 \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Imaging\IconRegistry::class)
88  ->registerIcon(
89  'wizard-backendlayout',
90  \TYPO3\CMS\Core\Imaging\IconProvider\FontawesomeIconProvider::class,
91  ['name' => 'table']
92  );
93 
94 // Include new content elements to modWizards
95 \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(
96  "@import 'EXT:frontend/Configuration/TSconfig/Page/Mod/Wizards/NewContentElement.tsconfig'"
97 );
98 // Include FormEngine adjustments
99 \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(
100  "@import 'EXT:frontend/Configuration/TSconfig/Page/TCEFORM.tsconfig'"
101 );
‪TYPO3
‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:5