‪TYPO3CMS  9.5
ext_localconf.php
Go to the documentation of this file.
1 <?php
2 defined('TYPO3_MODE') or die();
3 
4 call_user_func(function () {
5  // Register upgrade wizard in install tool
6  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/install']['update']['formFileExtension']
7  = \TYPO3\CMS\Form\Hooks\FormFileExtensionUpdate::class;
8 
9  if (\‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('filelist')) {
10  // Context menu item handling for form files
11  ‪$GLOBALS['TYPO3_CONF_VARS']['BE']['ContextMenu']['ItemProviders'][1530637161]
12  = \TYPO3\CMS\Form\Hooks\FormFileProvider::class;
13 
14  // File list edit icons
15  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['fileList']['editIconsHook'][1530637161]
16  = \TYPO3\CMS\Form\Hooks\FileListEditIconsHook::class;
17  }
18 
19  if (\‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('impexp')) {
20  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/impexp/class.tx_impexp.php']['before_addSysFileRecord'][1530637161]
21  = \TYPO3\CMS\Form\Hooks\ImportExportHook::class . '->beforeAddSysFileRecordOnImport';
22  }
23 
24  // Hook to enrich tt_content form flex element with finisher settings and form list drop down
25  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS'][\TYPO3\CMS\Core\Configuration\FlexForm\FlexFormTools::class]['flexParsing'][
26  \TYPO3\CMS\Form\Hooks\DataStructureIdentifierHook::class
27  ] = \TYPO3\CMS\Form\Hooks\DataStructureIdentifierHook::class;
28 
29  // Hook to count used forms elements in tt_content
30  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['GLOBAL']['softRefParser']['formPersistenceIdentifier'] =
31  \TYPO3\CMS\Form\Hooks\SoftReferenceParserHook::class;
32 
33  // Register for hook to show preview of tt_content element of CType="form_formframework" in page module
34  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/class.tx_cms_layout.php']['tt_content_drawItem']['form_formframework'] =
35  \TYPO3\CMS\Form\Hooks\FormPagePreviewRenderer::class;
36 
37  // Add new content element wizard entry
39  "@import 'EXT:form/Configuration/PageTS/modWizards.tsconfig'"
40  );
41 
42  // Add module configuration
44  'module.tx_form {
45  settings {
46  yamlConfigurations {
47  10 = EXT:form/Configuration/Yaml/BaseSetup.yaml
48  20 = EXT:form/Configuration/Yaml/FormEditorSetup.yaml
49  30 = EXT:form/Configuration/Yaml/FormEngineSetup.yaml
50  }
51  }
52  view {
53  templateRootPaths.10 = EXT:form/Resources/Private/Backend/Templates/
54  partialRootPaths.10 = EXT:form/Resources/Private/Backend/Partials/
55  layoutRootPaths.10 = EXT:form/Resources/Private/Backend/Layouts/
56  }
57 }'
58  );
59 
60  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/form']['afterSubmit'][1489772699]
61  = \TYPO3\CMS\Form\Hooks\FormElementHooks::class;
62 
63  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/form']['initializeFormElement'][1489772699]
64  = \TYPO3\CMS\Form\Hooks\FormElementHooks::class;
65 
66  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/form']['beforeRendering'][1489772699]
67  = \TYPO3\CMS\Form\Hooks\FormElementHooks::class;
68 
69  // FE file upload processing
70  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/form']['afterBuildingFinished'][1489772699]
71  = \TYPO3\CMS\Form\Mvc\Property\PropertyMappingConfiguration::class;
72  ‪$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['ext/form']['afterFormStateInitialized'][1613296803]
73  = \TYPO3\CMS\Form\Mvc\Property\PropertyMappingConfiguration::class;
74 
76  \‪TYPO3\CMS\Form\Mvc\Property\TypeConverter\FormDefinitionArrayConverter::class
77  );
78 
79  // Register "formvh:" namespace
80  ‪$GLOBALS['TYPO3_CONF_VARS']['SYS']['fluid']['namespaces']['formvh'][] = 'TYPO3\\CMS\\Form\\ViewHelpers';
81 
82  // Register FE plugin
84  'TYPO3.CMS.Form',
85  'Formframework',
86  ['FormFrontend' => 'render, perform'],
87  ['FormFrontend' => 'perform'],
88  \‪TYPO3\CMS\‪Extbase\Utility\ExtensionUtility::PLUGIN_TYPE_CONTENT_ELEMENT
89  );
90 
91  // Register slots for file handling
92  ‪$signalSlotDispatcher = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
93  \‪TYPO3\CMS\‪Extbase\SignalSlot\Dispatcher::class
94  );
95  ‪$signalSlotDispatcher->connect(
96  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
97  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreFileCreate,
98  \‪TYPO3\CMS\Form\Slot\FilePersistenceSlot::class,
99  'onPreFileCreate'
100  );
101  ‪$signalSlotDispatcher->connect(
102  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
103  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreFileAdd,
104  \‪TYPO3\CMS\Form\Slot\FilePersistenceSlot::class,
105  'onPreFileAdd'
106  );
107  ‪$signalSlotDispatcher->connect(
108  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
109  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreFileRename,
110  \‪TYPO3\CMS\Form\Slot\FilePersistenceSlot::class,
111  'onPreFileRename'
112  );
113  ‪$signalSlotDispatcher->connect(
114  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
115  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreFileReplace,
116  \‪TYPO3\CMS\Form\Slot\FilePersistenceSlot::class,
117  'onPreFileReplace'
118  );
119  ‪$signalSlotDispatcher->connect(
120  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
121  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreFileMove,
122  \‪TYPO3\CMS\Form\Slot\FilePersistenceSlot::class,
123  'onPreFileMove'
124  );
125  ‪$signalSlotDispatcher->connect(
126  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
127  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreFileSetContents,
128  \‪TYPO3\CMS\Form\Slot\FilePersistenceSlot::class,
129  'onPreFileSetContents'
130  );
131  ‪$signalSlotDispatcher->connect(
132  \‪TYPO3\CMS\Core\Resource\ResourceStorage::class,
133  \‪TYPO3\CMS\Core\Resource\ResourceStorageInterface::SIGNAL_PreGeneratePublicUrl,
134  \‪TYPO3\CMS\Form\Slot\ResourcePublicationSlot::class,
135  'onPreGeneratePublicUrl'
136  );
137 });
‪TYPO3\CMS\Extbase\Annotation
Definition: IgnoreValidation.php:4
‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility\addTypoScriptSetup
‪static addTypoScriptSetup($content)
Definition: ExtensionManagementUtility.php:1425
‪TYPO3
‪TYPO3\CMS\Extbase\Utility\ExtensionUtility\registerTypeConverter
‪static registerTypeConverter($typeConverterClassName)
Definition: ExtensionUtility.php:211
‪TYPO3\CMS\Extbase\Utility\ExtensionUtility\configurePlugin
‪static configurePlugin($extensionName, $pluginName, array $controllerActions, array $nonCacheableControllerActions=[], $pluginType=self::PLUGIN_TYPE_PLUGIN)
Definition: ExtensionUtility.php:43
‪$GLOBALS
‪$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['adminpanel']['modules']
Definition: ext_localconf.php:5
‪TYPO3\CMS\Core\Utility\ExtensionManagementUtility\addPageTSConfig
‪static addPageTSConfig($content)
Definition: ExtensionManagementUtility.php:978
‪$signalSlotDispatcher
‪$signalSlotDispatcher
Definition: ext_localconf.php:6