Attention
TYPO3 v11 has reached end-of-life as of October 31th 2024 and is no longer being maintained. Use the version switcher on the top left of this page to select documentation for a supported version of TYPO3.
Need more time before upgrading? You can purchase Extended Long Term Support (ELTS) for TYPO3 v11 here: TYPO3 ELTS.
Frontend controller
The frontend.
frontend request attribute provides access to the
\TYPO3\
object.
Example:
$frontendController = $request->getAttribute('frontend.controller');
$rootline = $frontendController->rootLine; // Mind the capital "L"
Copied!
Important
In former TYPO3 versions you have to retrieve the
Typo
via the global variable
$GLOBALS
. This should be avoided now, instead use the request
attribute.