Issue Bug Closed

#51891TypoScriptFrontendController 'Call to undefined method' when setting 'pageHeaderFooterTemplateFile'

Stan Angeloff 09/10/13, 15:48 updated 10/02/18, 12:10

Description

When a page is configured:

page = PAGE
page {
  typeNum = 0
  pageHeaderFooterTemplateFile = fileadmin/templates/frontend.html
}

the TypoScriptFrontendController tries to call setTemplateFile on itself, but that method does not exist.

diff --git a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php
index 20f7184..6d66720 100644
--- a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php
+++ b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php
@@ -2402,7 +2402,7 @@ class TypoScriptFrontendController {
                     if ($this->pSetup['pageHeaderFooterTemplateFile']) {
                         $file = $this->tmpl->getFileName($this->pSetup['pageHeaderFooterTemplateFile']);
                         if ($file) {
-                            $this->setTemplateFile($file);
+                            $this->getPageRenderer()->setTemplateFile($file);
                         }
                     }
                 }

Reviews 3