-->

TYPO3 error: Call to undefined method TYPO3\\CMS\\

2019-07-25 09:14发布

问题:

Getting the error when using the extension ke_serach 2.4.2 in TYPO3 8.7.1. Please refer the below image for reference.

getpagerenderError Image

回答1:

In TYPO3 8 LTS getPageRenderer() Methods Deprecated. Now, You can use PageRender Methods like below.

$pageRender = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Page\PageRenderer::class);
$pageRender->addJsFooterFile($jsFile, 'text/javascript', true, false, '', true);


回答2:

The extension ke_search is not compatible with TYPO3 8LTS yet. You can check the compatibility at the TER.

The exception is thrown because the extension still calls a method that was first deprecated in TYPO3 7LTS (see deprecation RST) and finally removed in TYPO3 8LTS (see breaking RST).