[TASK] Use general functionality for fetching templates
[Packages/TYPO3.CMS.git] / typo3 / sysext / backend / Classes / Template / DocumentTemplate.php
index dd9e90a..9d05214 100644 (file)
@@ -741,18 +741,8 @@ function jumpToUrl(URL) {
         if ($GLOBALS['TBE_STYLES']['htmlTemplates'][$filename]) {
             $filename = $GLOBALS['TBE_STYLES']['htmlTemplates'][$filename];
         }
-        if (GeneralUtility::isFirstPartOfStr($filename, 'EXT:')) {
-            $filename = GeneralUtility::getFileAbsFileName($filename);
-        } elseif (!GeneralUtility::isAbsPath($filename)) {
-            $filename = GeneralUtility::resolveBackPath($filename);
-        } elseif (!GeneralUtility::isAllowedAbsPath($filename)) {
-            $filename = '';
-        }
-        $htmlTemplate = '';
-        if ($filename !== '') {
-            $htmlTemplate = file_get_contents($filename);
-        }
-        return $htmlTemplate;
+        $filename = GeneralUtility::getFileAbsFileName($filename);
+        return $filename !== '' ? file_get_contents($filename) : '';
     }
 
     /**