-
Notifications
You must be signed in to change notification settings - Fork 23
/
ext_localconf.php
51 lines (42 loc) · 1.61 KB
/
ext_localconf.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
use Fab\MediaUpload\Controller\MediaUploadController;
if (!defined('TYPO3_MODE')) die ('Access denied.');
call_user_func(function () {
$configuration = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Configuration\ExtensionConfiguration::class) ->get('media_upload');
if (false === isset($configuration['autoload_typoscript']) || true === (bool)$configuration['autoload_typoscript']) {
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTypoScript(
'media_upload',
'constants',
'<INCLUDE_TYPOSCRIPT: source="FILE:EXT:media_upload/Configuration/TypoScript/constants.typoscript">'
);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTypoScript(
'media_upload',
'setup',
'<INCLUDE_TYPOSCRIPT: source="FILE:EXT:media_upload/Configuration/TypoScript/setup.typoscript">'
);
}
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
'MediaUpload',
'Upload',
[
MediaUploadController::class => 'upload',
],
// non-cacheable actions
[
MediaUploadController::class => 'upload',
]
);
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::configurePlugin(
'MediaUpload',
'Delete',
[
MediaUploadController::class => 'delete',
],
// non-cacheable actions
[
MediaUploadController::class => 'delete',
]
);
// command line is replaced by symphony command:
// ./vendor/bin/typo3cms mediaupload:removeTempFiles rundry=1
});