-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathext_tables.php
More file actions
24 lines (21 loc) · 858 Bytes
/
Copy pathext_tables.php
File metadata and controls
24 lines (21 loc) · 858 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php
use Psr\Http\Message\ServerRequestInterface;
if (!defined('TYPO3')) {
die('Access denied.');
}
(function() {
if(true === isset($GLOBALS['TYPO3_CONF_VARS']['EXTENSIONS']['tgm_copyright']['copyrightRequired'])
&& true === (bool) $GLOBALS['TYPO3_CONF_VARS']['EXTENSIONS']['tgm_copyright']['copyrightRequired']
&& (
!(($GLOBALS['TYPO3_REQUEST'] ?? null) instanceof ServerRequestInterface)
|| false === \TYPO3\CMS\Core\Http\ApplicationType::fromRequest($GLOBALS['TYPO3_REQUEST'])->isFrontend()
)
)
{
try {
$pageRenderer = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Page\PageRenderer::class);
$pageRenderer->loadJavaScriptModule('@paulbeck/tgmcopyright/copyrightmandatory');
} catch (Exception $exc) {
}
}
})();