‪TYPO3CMS  10.4
TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController Class Reference
Inheritance diagram for TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController:

Public Member Functions

 __construct ($context=null, $siteOrId=null, $siteLanguageOrType=null, $pageArguments=null, $cHashOrFrontendUser=null, $_2=null, $MP=null)
 
 setContentType ($contentType)
 
 initUserGroups ()
 
bool isUserOrGroupSet ()
 
 clear_preview ()
 
bool isBackendUserLoggedIn ()
 
 determineId (ServerRequestInterface $request=null)
 
 fetch_the_id (ServerRequestInterface $request=null)
 
bool checkEnableFields ($row, $bypassGroupCheck=false)
 
bool checkPageGroupAccess ($row)
 
bool checkPagerecordForIncludeSection (array $row)
 
bool checkIfLoginAllowedInBranch ()
 
array getPageAccessFailureReasons (string $failureReasonCode=null)
 
 getPageAndRootlineWithDomain ($rootPageId, ServerRequestInterface $request)
 
 reqCHash ()
 
 getFromCache (ServerRequestInterface $request=null)
 
array getFromCache_queryRow ()
 
bool headerNoCache (ServerRequestInterface $request=null)
 
 getConfigArray (ServerRequestInterface $request=null)
 
 settingLanguage (ServerRequestInterface $request=null)
 
 settingLocale ()
 
 calculateLinkVars (array $queryParams)
 
string null getRedirectUriForMountPoint (ServerRequestInterface $request)
 
string null getRedirectUriForShortcut (ServerRequestInterface $request)
 
bool isGeneratePage ()
 
 clearPageCacheContent ()
 
 releaseLocks ()
 
 addCacheTags (array $tags)
 
array getPageCacheTags ()
 
 generatePage_preProcessing ()
 
 preparePageContentGeneration (ServerRequestInterface $request)
 
 generatePage_postProcessing ()
 
string generatePageTitle ()
 
 INTincScript ()
 
 INTincScript_loadJSCode ()
 
bool isINTincScript ()
 
bool isOutputting (bool $isCoreCall=false)
 
 processContentForOutput (bool $isCoreCall=false)
 
ResponseInterface applyHttpHeadersToResponse (ResponseInterface $response)
 
bool isStaticCacheble ()
 
 newCObj ()
 
 setAbsRefPrefix ()
 
string baseUrlWrap ($url)
 
 logDeprecatedTyposcript ($typoScriptProperty, $explanation='')
 
bool doWorkspacePreview ()
 
int whichWorkspace ()
 
array getPagesTSconfig ()
 
 setJS ($key, $content='')
 
string uniqueHash ($str='')
 
 set_no_cache ($reason='', $internal=false)
 
 set_cache_timeout_default ($seconds)
 
int get_cache_timeout ()
 
string sL ($input)
 
string convOutputCharset ($content)
 
int getRequestedId ()
 
 getLanguage ()
 
 getSite ()
 
 getContext ()
 
 getPageArguments ()
 
bool __isset (string $propertyName)
 
mixed __get (string $propertyName)
 
 __set (string $propertyName, $propertyValue)
 
 __unset (string $propertyName)
 

Static Public Member Functions

static TypoScriptFrontendController getGlobalInstance ()
 

Public Attributes

string $id = ''
 
int string $type = ''
 
bool $no_cache = false
 
array $rootLine = array( )
 
array $page = array( )
 
int $contentPid = 0
 
PageRepository string $sys_page = ''
 
int $pageNotFound = 0
 
string $MP = ''
 
FrontendUserAuthentication string $fe_user = ''
 
int $simUserGroup = 0
 
array $config = array( )
 
TemplateService $tmpl
 
array $all = array( )
 
string $sPre = ''
 
array string $pSetup = ''
 
string $newHash = ''
 
array $additionalHeaderData = array( )
 
array $additionalFooterData = array( )
 
array $additionalJavaScript = array( )
 
array $additionalCSS = array( )
 
string $JSCode
 
string $inlineJS
 
string $divSection = ''
 
string $intTarget = ''
 
string $extTarget = ''
 
string $fileTarget = ''
 
string int $spamProtectEmailAddresses = 0
 
string $absRefPrefix = ''
 
string $ATagParams = ''
 
string $sWordRegEx = ''
 
string $sWordList = ''
 
string $linkVars = ''
 
string $displayEditIcons = ''
 
string $displayFieldEditIcons = ''
 
array $applicationData = array( )
 
array $register = array( )
 
array $registerStack = array( )
 
int $cObjectDepthCounter = 50
 
array $recordRegister = array( )
 
string $currentRecord = ''
 
array $accessKey = array( )
 
string $indexedDocTitle = ''
 
string $baseUrl = ''
 
ContentObjectRenderer $cObj
 
string $content = ''
 
string $metaCharset = 'utf-8'
 
string $xhtmlDoctype = ''
 
int $xhtmlVersion
 

Protected Member Functions

 initPageRenderer ()
 
 initCaches ()
 
string null applyPreviewSettings ($backendUser=null)
 
bool determineIdIsHiddenPage ()
 
 getPageAndRootline (ServerRequestInterface $request)
 
 resolveTranslatedPageId ()
 
bool checkRootlineForIncludeSection ()
 
 setPageArguments (PageArguments $pageArguments)
 
array getRelevantParametersForCachingFromPageArguments (PageArguments $pageArguments)
 
 populatePageDataFromCache (array $cachedData)
 
string getHash ()
 
string getLockHash ()
 
string createHashBase ($createLockHashBase=false)
 
 updateRootLinesWithTranslations ()
 
 checkTranslatedShortcut (int $languageId, ServerRequestInterface $request)
 
array splitLinkVarsString (string $string)
 
bool isAllowedLinkVarValue (string $haystack, string $needle)
 
string getUriToCurrentPageForRedirect (ServerRequestInterface $request)
 
 realPageCacheContent ()
 
 setPageCacheContent ($content, $data, $expirationTstamp)
 
 setSysLastChanged ()
 
 setRegisterValueForSysLastChanged (array $page)
 
int resolveContentPid (ServerRequestInterface $request)
 
 initializeSearchWordData ($searchWords)
 
string printTitle (string $pageTitle, bool $noTitle=false, bool $showTitleFirst=false, string $pageTitleSeparator='')
 
string getWebsiteTitle ()
 
 recursivelyReplaceIntPlaceholdersInContent ()
 
 processNonCacheableContentPartsAndSubstituteContentMarkers (array $nonCacheableData)
 
array getCacheHeaders ()
 
 disableCache ()
 
 setOutputLanguage ()
 
int calculatePageCacheTimeout ()
 
array getCurrentPageCacheConfiguration ()
 
int getFirstTimeValueForRecord ($tableDef, $now)
 
 acquireLock ($type, $key)
 
 releaseLock ($type)
 
 getAdditionalHeaders ()
 
 isInPreviewMode ()
 
TYPO3 CMS Backend FrontendBackendUserAuthentication getBackendUser ()
 
TimeTracker getTimeTracker ()
 

Protected Attributes

Site $site
 
SiteLanguage $language
 
string $cHash = ''
 
PageArguments $pageArguments
 
array null $originalMountPointPage
 
array null $originalShortcutPage
 
int $domainStartPage = 0
 
array $pageAccessFailureHistory = array( )
 
bool $loginAllowedInBranch = true
 
string $loginAllowedInBranch_mode = ''
 
int $fePreview = 0
 
int $cacheTimeOutDefault = 86400
 
bool $cacheContentFlag = false
 
int $cacheExpires = 0
 
bool $isClientCachable = false
 
bool $no_cacheBeforePageGen = false
 
array $cHash_array = array( )
 
array string $pagesTSconfig = ''
 
string $sys_language_isocode = ''
 
int $uniqueCounter = 0
 
string $uniqueString = ''
 
LanguageService $languageService
 
LockingStrategyInterface[][] $locks = array( )
 
PageRenderer $pageRenderer
 
TYPO3 CMS Core Cache Frontend FrontendInterface $pageCache
 
array $pageCacheTags = array( )
 
string $contentType = 'text/html'
 
int $requestedId
 
Context $context
 

Private Member Functions

 initializeContextWithGlobalFallback ($context)
 
 initializeSiteWithCompatibility ($siteOrId, ServerRequestInterface $request)
 
 initializeSiteLanguageWithCompatibility ($siteLanguageOrType, ServerRequestInterface $request)
 
PageArguments buildPageArgumentsWithFallback ($pageArguments, ServerRequestInterface $request)
 
PageArguments initializeFrontendUserOrUpdateCHashArgument ($cHashOrFrontendUser, PageArguments $pageArguments)
 
PageArguments initializeLegacyMountPointArgument (?string $MP, PageArguments $pageArguments)
 

Private Attributes

string[] $deprecatedPublicProperties
 
bool $forceTemplateParsing = false
 
array $imagesOnPage = array( )
 
array $lastImageInfo = array( )
 

Detailed Description

Class for the built TypoScript based frontend. Instantiated in \TYPO3\CMS\Frontend\Http\RequestHandler as the global object TSFE.

Main frontend class, instantiated in \TYPO3\CMS\Frontend\Http\RequestHandler as the global object TSFE.

This class has a lot of functions and internal variable which are used from \TYPO3\CMS\Frontend\Http\RequestHandler

The class is instantiated as $GLOBALS['TSFE'] in \TYPO3\CMS\Frontend\Http\RequestHandler.

The use of this class should be inspired by the order of function calls as found in \TYPO3\CMS\Frontend\Http\RequestHandler.

Definition at line 97 of file TypoScriptFrontendController.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::__construct (   $context = null,
  $siteOrId = null,
  $siteLanguageOrType = null,
  $pageArguments = null,
  $cHashOrFrontendUser = null,
  $_2 = null,
  $MP = null 
)

Since TYPO3 v10.0, TSFE is composed out of

  • ‪Context
  • ‪Site
  • ‪SiteLanguage
  • ‪PageArguments (containing ID, Type, cHash and MP arguments)

With TYPO3 v11, they will become mandatory and the method arguments will become strongly typed. For TYPO3 v10 this is built in a way to ensure maximum compatibility.

Also sets a unique string (->uniqueString) for this script instance; A md5 hash of the microtime()

Parameters
Context | array | null$context‪the Context object to work on, previously defined to set TYPO3_CONF_VARS
mixed | SiteInterface$siteOrId‪The resolved site to work on, previously this was the value of GeneralUtility::_GP('id')
SiteLanguage | int | string$siteLanguageOrType‪The resolved language to work on, previously the value of GeneralUtility::_GP('type')
bool | string | PageArguments | null$pageArguments‪The PageArguments object containing ID, type and GET parameters, previously unused or the value of GeneralUtility::_GP('no_cache')
string | FrontendUserAuthentication | null$cHashOrFrontendUser‪FrontendUserAuthentication object, previously the value of GeneralUtility::_GP('cHash'), use the PageArguments object instead, will be removed in TYPO3 v11.0
string | null$_2‪previously was used to define the jumpURL, use the PageArguments object instead, will be removed in TYPO3 v11.0
string | null$MP‪The value of GeneralUtility::_GP('MP'), use the PageArguments object instead, will be removed in TYPO3 v11.0

Definition at line 628 of file TypoScriptFrontendController.php.

References $GLOBALS, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$pageArguments, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\buildPageArgumentsWithFallback(), TYPO3\CMS\Core\Http\ServerRequestFactory\fromGlobals(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initCaches(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initializeContextWithGlobalFallback(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initializeFrontendUserOrUpdateCHashArgument(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initializeLegacyMountPointArgument(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initializeSiteLanguageWithCompatibility(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initializeSiteWithCompatibility(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initPageRenderer(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setOutputLanguage(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setPageArguments().

Member Function Documentation

◆ __get()

mixed TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::__get ( string  $propertyName)

Gets the value of the property of the given name if tagged.

The evaluation is done in the assumption that this method is never reached for a public property.

Parameters
string$propertyName
Returns
‪mixed

Definition at line 4038 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getRelevantParametersForCachingFromPageArguments().

◆ __isset()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::__isset ( string  $propertyName)

Deprecation messages for TYPO3 10 - public properties of TSFE which have been (re)moved Checks if the property of the given name is set.

Unmarked protected properties must return false as usual. Marked properties are evaluated by isset().

This method is not called for public properties.

Parameters
string$propertyName
Returns
‪bool

Definition at line 4000 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getRelevantParametersForCachingFromPageArguments().

◆ __set()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::__set ( string  $propertyName,
  $propertyValue 
)

Sets the property of the given name if tagged.

Additionally it's allowed to set unknown properties.

The evaluation is done in the assumption that this method is never reached for a public property.

Parameters
string$propertyName
mixed$propertyValue

Definition at line 4083 of file TypoScriptFrontendController.php.

◆ __unset()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::__unset ( string  $propertyName)

Unsets the property of the given name if tagged.

Parameters
string$propertyName

Definition at line 4118 of file TypoScriptFrontendController.php.

◆ acquireLock()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::acquireLock (   $type,
  $key 
)
protected

Acquire a page specific lock

The schematics here is:

  • ‪First acquire an access lock. This is using the type of the requested lock as key. Since the number of types is rather limited we can use the type as key as it will only eat up a limited number of lock resources on the system (files, semaphores)
  • ‪Second, we acquire the actual lock (named page lock). We can be sure we are the only process at this very moment, hence we either get the lock for the given key or we get an error as we request a non-blocking mode.

Interleaving two locks is extremely important, because the actual page lock uses a hash value as key (see callers of this function). If we would simply employ a normal blocking lock, we would get a potentially unlimited (number of pages at least) number of different locks. Depending on the available locking methods on the system we might run out of available resources. (e.g. maximum limit of semaphores is a system setting and applies to the whole system) We therefore must make sure that page locks are destroyed again if they are not used anymore, such that we never use more locking resources than parallel requests to different pages (hashes). In order to ensure this, we need to guarantee that no other process is waiting on a page lock when the process currently having the lock on the page lock is about to release the lock again. This can only be achieved by using a non-blocking mode, such that a process is never put into wait state by the kernel, but only checks the availability of the lock. The access lock is our guard to be sure that no two processes are at the same time releasing/destroying a page lock, whilst the other one tries to get a lock for this page lock. The only drawback of this implementation is that we basically have to poll the availability of the page lock.

Note that the access lock resources are NEVER deleted/destroyed, otherwise the whole thing would be broken.

Parameters
string$type
string$key
Exceptions

Definition at line 3825 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$type, TYPO3\CMS\Core\Locking\LockingStrategyInterface\LOCK_CAPABILITY_EXCLUSIVE, and TYPO3\CMS\Core\Locking\LockingStrategyInterface\LOCK_CAPABILITY_NOBLOCK.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getFromCache().

◆ addCacheTags()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::addCacheTags ( array  $tags)

Adds tags to this page's cache entry, you can then f.e. remove cache entries by tag

Parameters
array$tags‪An array of tag

Definition at line 2646 of file TypoScriptFrontendController.php.

◆ applyHttpHeadersToResponse()

ResponseInterface TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::applyHttpHeadersToResponse ( ResponseInterface  $response)

◆ applyPreviewSettings()

string null TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::applyPreviewSettings (   $backendUser = null)
protected

Evaluates admin panel or workspace settings to see if visibility settings like

  • ‪Preview Aspect: isPreview
  • ‪Visibility Aspect: includeHiddenPages
  • ‪Visibility Aspect: includeHiddenContent
  • ‪$simUserGroup should be applied to the current object.
Parameters
FrontendBackendUserAuthentication$backendUser
Returns
‪string|null null if no changes to the current frontend usergroups have been made, otherwise the original list of frontend usergroups

Definition at line 998 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineIdIsHiddenPage(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\whichWorkspace().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineId().

◆ baseUrlWrap()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::baseUrlWrap (   $url)

Prefixing the input URL with ->baseUrl If ->baseUrl is set and the input url is not absolute in some way. Designed as a wrapper functions for use with all frontend links that are processed by JavaScript (for "realurl" compatibility!). So each time a URL goes into window.open, window.location.href or otherwise, wrap it with this function!

Parameters
string$url‪Input URL, relative or absolute
Returns
‪string Processed input value.

Definition at line 3384 of file TypoScriptFrontendController.php.

◆ buildPageArgumentsWithFallback()

PageArguments TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::buildPageArgumentsWithFallback (   $pageArguments,
ServerRequestInterface  $request 
)
private

Since TYPO3 v10.0, the fourth constructor argument should be of type PageArguments. However, until TYPO3 v8, this was the GET/POST parameter "no_cache". If no PageArguments object is given, the given request is checked for the PageArguments.

Parameters
bool | string | PageArguments | null$pageArguments
ServerRequestInterface$request
Returns
‪PageArguments

Definition at line 730 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$pageArguments.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ calculateLinkVars()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::calculateLinkVars ( array  $queryParams)

◆ calculatePageCacheTimeout()

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::calculatePageCacheTimeout ( )
protected

Calculates page cache timeout according to the records with starttime/endtime on the page.

Returns
‪int Page cache timeout or PHP_INT_MAX if cannot be determined

Definition at line 3654 of file TypoScriptFrontendController.php.

References $GLOBALS, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getCurrentPageCacheConfiguration(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getFirstTimeValueForRecord().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\get_cache_timeout().

◆ checkEnableFields()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkEnableFields (   $row,
  $bypassGroupCheck = false 
)

Checks page record for enableFields Returns TRUE if enableFields does not disable the page record. Takes notice of the includeHiddenPages visibility aspect flag and uses SIM_ACCESS_TIME for start/endtime evaluation

Parameters
array$row‪The page record to evaluate (needs fields: hidden, starttime, endtime, fe_group)
bool$bypassGroupCheck‪Bypass group-check
Returns
‪bool TRUE, if record is viewable.
See also
‪\TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getTreeList()
checkPagerecordForIncludeSection()

Definition at line 1542 of file TypoScriptFrontendController.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkPagerecordForIncludeSection().

◆ checkIfLoginAllowedInBranch()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkIfLoginAllowedInBranch ( )

Checks if logins are allowed in the current branch of the page tree. Traverses the full root line and returns TRUE if logins are OK, otherwise FALSE (and then the login user must be unset!)

Returns
‪bool returns TRUE if logins are OK, otherwise FALSE (and then the login user must be unset!)

Definition at line 1601 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineId().

◆ checkPageGroupAccess()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkPageGroupAccess (   $row)

Check group access against a page record

Parameters
array$row‪The page record to evaluate (needs field: fe_group)
Returns
‪bool TRUE, if group access is granted.

Definition at line 1568 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAccessFailureReasons().

◆ checkPagerecordForIncludeSection()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkPagerecordForIncludeSection ( array  $row)

Checks if the current page of the root line is visible.

If the field extendToSubpages is 0, access is granted, else the fields hidden, starttime, endtime, fe_group are evaluated.

Todo:
‪Find a better name, i.e. isVisibleRecord()
Parameters
array$row‪The page record
Returns
‪bool true if visible
See also
checkEnableFields()
‪\TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getTreeList()
checkRootlineForIncludeSection()

Definition at line 1591 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkEnableFields().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkRootlineForIncludeSection().

◆ checkRootlineForIncludeSection()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkRootlineForIncludeSection ( )
protected

Checks if visibility of the page is blocked upwards in the root line.

If any page in the root line is blocking visibility, true is returned.

All pages from the blocking page downwards are removed from the root line, so that the remaining pages can be used to relocate the page up to lowest visible page.

The blocking feature of a page must be turned on by setting the page record field 'extendToSubpages' to 1 in case of hidden, starttime, endtime or fe_group restrictions.

Additionally this method checks for backend user sections in root line and if found evaluates if a backend user is logged in and has access.

Recyclers are also checked and trigger page not found if found in root line.

Todo:

Find a better name, i.e. checkVisibilityByRootLine

Invert boolean return value. Return true if visible.

Returns
‪bool

Definition at line 1474 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkPagerecordForIncludeSection(), TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_BE_USER_SECTION, TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_RECYCLER, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isBackendUserLoggedIn(), and TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_SHOW.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAndRootline().

◆ checkTranslatedShortcut()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkTranslatedShortcut ( int  $languageId,
ServerRequestInterface  $request 
)
protected

Checks whether a translated shortcut page has a different shortcut target than the original language page. If that is the case, things get corrected to follow that alternative shortcut

Parameters
int$languageId
ServerRequestInterface$request

Definition at line 2294 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\fetch_the_id().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\settingLanguage().

◆ clear_preview()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::clear_preview ( )

Clears the preview-flags, sets sim_exec_time to current time. Hidden pages must be hidden as default, $GLOBALS['SIM_EXEC_TIME'] is set to $GLOBALS['EXEC_TIME'] in bootstrap initializeGlobalTimeVariables(). Alter it by adding or subtracting seconds.

Definition at line 904 of file TypoScriptFrontendController.php.

References $GLOBALS, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isInPreviewMode().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineId().

◆ clearPageCacheContent()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::clearPageCacheContent ( )

Clears cache content (for $this->newHash)

Definition at line 2584 of file TypoScriptFrontendController.php.

◆ convOutputCharset()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::convOutputCharset (   $content)

Converts input string from utf-8 to metaCharset IF the two charsets are different.

Parameters
string$content‪Content to be converted.
Returns
‪string Converted content string.
Exceptions

Definition at line 3635 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$content.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\generatePage_postProcessing(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\processNonCacheableContentPartsAndSubstituteContentMarkers().

◆ createHashBase()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::createHashBase (   $createLockHashBase = false)
protected

Calculates the cache-hash (or the lock-hash) This hash is unique to the template, the variables ->id, ->type, list of frontend user groups, ->MP (Mount Points) and cHash array Used to get and later store the cached data.

Parameters
bool$createLockHashBase‪Whether to create the lock hash, which doesn't contain the "this->all" (the template information)
Returns
‪string the serialized hash base

Definition at line 1968 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$all, $GLOBALS, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$MP, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$type, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getRelevantParametersForCachingFromPageArguments().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getHash(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getLockHash().

◆ determineId()

◆ determineIdIsHiddenPage()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::determineIdIsHiddenPage ( )
protected

◆ disableCache()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::disableCache ( )
protected

◆ doWorkspacePreview()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::doWorkspacePreview ( )

◆ fetch_the_id()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::fetch_the_id ( ServerRequestInterface  $request = null)

Resolves the page id and sets up several related properties.

If $this->id is not set at all or is not a plain integer, the method does it's best to set the value to an integer. Resolving is based on this options:

  • ‪Splitting $this->id if it contains an additional type parameter.
  • ‪Finding the domain record start page
  • ‪First visible page
  • ‪Relocating the id below the domain record if outside

The following properties may be set up or updated:

  • ‪id
  • ‪requestedId
  • ‪type
  • ‪sys_page
  • ‪sys_page->where_groupAccess
  • ‪sys_page->where_hid_del
  • ‪Context: FrontendUser Aspect
  • ‪no_cache
  • ‪register['SYS_LASTCHANGED']
  • ‪pageNotFound

Via getPageAndRootlineWithDomain()

  • ‪rootLine
  • ‪page
  • ‪MP
  • ‪originalShortcutPage
  • ‪originalMountPointPage
  • ‪pageAccessFailureHistory['direct_access']
  • pageNotFound

    Todo:
    :

On the first impression the method does to much. This is increased by the fact, that is is called repeated times by the method determineId. The reasons are manifold.

1.) The first part, the creation of sys_page and the type resolution don't need to be repeated. They could be separated to be called only once.

2.) The user group setup could be done once on a higher level.

3.) The workflow of the resolution could be elaborated to be less tangled. Maybe the check of the page id to be below the domain via the root line doesn't need to be done each time, but for the final result only.

4.) The root line does not need to be directly addressed by this class. A root line is always related to one page. The rootline could be handled indirectly by page objects. Page objects still don't exist.

Parameters
ServerRequestInterface | null$request

Definition at line 1149 of file TypoScriptFrontendController.php.

References $GLOBALS, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$id, TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\ACCESS_DENIED_HOST_PAGE_MISMATCH, TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\ACCESS_DENIED_PAGE_NOT_RESOLVED, TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\ACCESS_DENIED_SUBSECTION_NOT_RESOLVED, TYPO3\CMS\Core\Http\ServerRequestFactory\fromGlobals(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAccessFailureReasons(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAndRootlineWithDomain(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getTimeTracker(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initUserGroups(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setRegisterValueForSysLastChanged().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkTranslatedShortcut(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineId().

◆ generatePage_postProcessing()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::generatePage_postProcessing ( )

◆ generatePage_preProcessing()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::generatePage_preProcessing ( )

Does some processing BEFORE the page content is generated / built.

Definition at line 2667 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$no_cache, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getHash().

◆ generatePageTitle()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::generatePageTitle ( )

Generate the page title, can be called multiple times, as PageTitleProvider might have been modified by an uncached plugin etc.

Returns
‪string the generated page title

Definition at line 2846 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\printTitle().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript(), and TYPO3\CMS\Frontend\Http\RequestHandler\processHtmlBasedRenderingSettings().

◆ get_cache_timeout()

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::get_cache_timeout ( )

◆ getAdditionalHeaders()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getAdditionalHeaders ( )
protected

Send additional headers from config.additionalHeaders

Definition at line 3889 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\applyHttpHeadersToResponse().

◆ getBackendUser()

TYPO3 CMS Backend FrontendBackendUserAuthentication TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getBackendUser ( )
protected

Returns the current BE user.

Returns
‪\TYPO3\CMS\Backend\FrontendBackendUserAuthentication

Definition at line 3927 of file TypoScriptFrontendController.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineId().

◆ getCacheHeaders()

◆ getConfigArray()

◆ getContext()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getContext ( )

◆ getCurrentPageCacheConfiguration()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getCurrentPageCacheConfiguration ( )
protected

Obtains a list of table/pid pairs to consider for page caching.

TS configuration looks like this:

The cache lifetime of all pages takes starttime and endtime of news records of page 14 into account: config.cache.all = tt_news:14

The cache.lifetime of the current page allows to take records (e.g. fe_users) into account: config.cache.all = fe_users:current

The cache lifetime of page 42 takes starttime and endtime of news records of page 15 and addresses of page 16 into account: config.cache.42 = tt_news:15,tt_address:16

Returns
‪array Array of 'tablename:pid' pairs. There is at least a current page id in the array
See also
TypoScriptFrontendController::calculatePageCacheTimeout()

Definition at line 3689 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$id, and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\calculatePageCacheTimeout().

◆ getFirstTimeValueForRecord()

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getFirstTimeValueForRecord (   $tableDef,
  $now 
)
protected

Find the minimum starttime or endtime value in the table and pid that is greater than the current time.

Parameters
string$tableDef‪Table definition (format tablename:pid)
int$now‪"Now" time value
Exceptions

Definition at line 3710 of file TypoScriptFrontendController.php.

References if, and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\calculatePageCacheTimeout().

◆ getFromCache()

◆ getFromCache_queryRow()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getFromCache_queryRow ( )

◆ getGlobalInstance()

static TypoScriptFrontendController TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getGlobalInstance ( )
static

Return the global instance of this class.

Intended to be used as prototype factory for this class, see Services.yaml. This is required as long as TypoScriptFrontendController needs request dependent constructor parameters. Once that has been refactored this factory will be removed.

Returns
TypoScriptFrontendController

Definition at line 3951 of file TypoScriptFrontendController.php.

References $GLOBALS.

◆ getHash()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getHash ( )
protected

Calculates the cache-hash This hash is unique to the template, the variables ->id, ->type, list of fe user groups, ->MP (Mount Points) and cHash array Used to get and later store the cached data.

Returns
‪string MD5 hash of serialized hash base from createHashBase()
See also
getFromCache()
getLockHash()

Definition at line 1939 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\createHashBase().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\generatePage_preProcessing(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getFromCache().

◆ getLanguage()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getLanguage ( )

◆ getLockHash()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getLockHash ( )
protected

Calculates the lock-hash This hash is unique to the above hash, except that it doesn't contain the template information in $this->all.

Returns
‪string MD5 hash
See also
getFromCache()
getHash()

Definition at line 1952 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\createHashBase().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getFromCache().

◆ getPageAccessFailureReasons()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getPageAccessFailureReasons ( string  $failureReasonCode = null)

Analysing $this->pageAccessFailureHistory into a summary array telling which features disabled display and on which pages and conditions. That data can be used inside a page-not-found handler

Parameters
string$failureReasonCode‪the error code to be attached (optional), see PageAccessFailureReasons list for details
Returns
‪array Summary of why page access was not allowed.

Definition at line 1631 of file TypoScriptFrontendController.php.

References $GLOBALS, $output, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkPageGroupAccess().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\fetch_the_id(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAndRootline().

◆ getPageAndRootline()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getPageAndRootline ( ServerRequestInterface  $request)
protected

Loads the page and root line records based on $this->id

A final page and the matching root line are determined and loaded by the algorithm defined by this method.

First it loads the initial page from the page repository for $this->id. If that can't be loaded directly, it gets the root line for $this->id. It walks up the root line towards the root page until the page repository can deliver a page record. (The loading restrictions of the root line records are more liberal than that of the page record.)

Now the page type is evaluated and handled if necessary. If the page is a short cut, it is replaced by the target page. If the page is a mount point in overlay mode, the page is replaced by the mounted page.

After this potential replacements are done, the root line is loaded (again) for this page record. It walks up the root line up to the first viewable record.

(While upon the first accessibility check of the root line it was done by loading page by page from the page repository, this time the method checkRootlineForIncludeSection() is used to find the most distant accessible page within the root line.)

Having found the final page id, the page record and the root line are loaded for last time by this method.

Exceptions may be thrown for DOKTYPE_SPACER and not loadable page records or root lines.

May set or update this properties:

See also
TypoScriptFrontendController::$id
TypoScriptFrontendController::$MP
TypoScriptFrontendController::$page
TypoScriptFrontendController::$pageNotFound
TypoScriptFrontendController::$pageAccessFailureHistory
TypoScriptFrontendController::$originalMountPointPage
TypoScriptFrontendController::$originalShortcutPage
Exceptions

Definition at line 1264 of file TypoScriptFrontendController.php.

References $GLOBALS, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$page, TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\ACCESS_DENIED_INVALID_PAGETYPE, TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\ACCESS_DENIED_SUBSECTION_NOT_RESOLVED, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\checkRootlineForIncludeSection(), TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_MOUNTPOINT, TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_SHORTCUT, TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_SPACER, TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_SYSFOLDER, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAccessFailureReasons(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isBackendUserLoggedIn(), TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\PAGE_NOT_FOUND, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\resolveTranslatedPageId(), and TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\ROOTLINE_BROKEN.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAndRootlineWithDomain().

◆ getPageAndRootlineWithDomain()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getPageAndRootlineWithDomain (   $rootPageId,
ServerRequestInterface  $request 
)

Gets ->page and ->rootline information based on ->id. ->id may change during this operation. If not inside a site, then default to first page in site.

Parameters
int$rootPageIdPage uid of the page where the found site is located

Definition at line 1668 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAndRootline().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\fetch_the_id().

◆ getPageArguments()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getPageArguments ( )

◆ getPageCacheTags()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getPageCacheTags ( )

◆ getPagesTSconfig()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getPagesTSconfig ( )

Returns the pages TSconfig array based on the current ->rootLine

Returns
‪array

Definition at line 3445 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$pagesTSconfig, and $parser.

◆ getRedirectUriForMountPoint()

string null TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getRedirectUriForMountPoint ( ServerRequestInterface  $request)

Returns URI of target page, if the current page is an overlaid mountpoint.

If the current page is of type mountpoint and should be overlaid with the contents of the mountpoint page and is accessed directly, the user will be redirected to the mountpoint context.

Parameters
ServerRequestInterface$request
Returns
‪string|null

Definition at line 2454 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_MOUNTPOINT, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getUriToCurrentPageForRedirect().

◆ getRedirectUriForShortcut()

string null TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getRedirectUriForShortcut ( ServerRequestInterface  $request)

Returns URI of target page, if the current page is a Shortcut.

If the current page is of type shortcut and accessed directly via its URL, the user will be redirected to shortcut target.

Parameters
ServerRequestInterface$request
Returns
‪string|null

Definition at line 2473 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Core\Domain\Repository\PageRepository\DOKTYPE_SHORTCUT, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getUriToCurrentPageForRedirect().

◆ getRelevantParametersForCachingFromPageArguments()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getRelevantParametersForCachingFromPageArguments ( PageArguments  $pageArguments)
protected

Fetches the arguments that are relevant for creating the hash base from the given PageArguments object. Excluded parameters are not taken into account when calculating the hash base.

Parameters
PageArguments$pageArguments
Returns
‪array

Definition at line 1745 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$pageArguments, TYPO3\CMS\Core\Utility\HttpUtility\buildQueryString(), and TYPO3\CMS\Core\Routing\PageArguments\getPageId().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__get(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__isset(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\createHashBase().

◆ getRequestedId()

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getRequestedId ( )

Fetches the originally requested id, falls back to $this->id

Returns
‪int the originally requested page uid
See also
fetch_the_id()

Definition at line 3786 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$id.

◆ getSite()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getSite ( )

◆ getTimeTracker()

◆ getUriToCurrentPageForRedirect()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getUriToCurrentPageForRedirect ( ServerRequestInterface  $request)
protected

◆ getWebsiteTitle()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::getWebsiteTitle ( )
protected

◆ headerNoCache()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::headerNoCache ( ServerRequestInterface  $request = null)

Detecting if shift-reload has been clicked Will not be called if re-generation of page happens by other reasons (for instance that the page is not in cache yet!) Also, a backend user MUST be logged in for the shift-reload to be detected due to DoS-attack-security reasons.

Parameters
ServerRequestInterface | null$request
Returns
‪bool If shift-reload in client browser has been clicked, disable getting cached page (and regenerate it).

Definition at line 1909 of file TypoScriptFrontendController.php.

References $GLOBALS, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isBackendUserLoggedIn().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getFromCache().

◆ initCaches()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initCaches ( )
protected

Initializes the caching system.

Definition at line 835 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ initializeContextWithGlobalFallback()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initializeContextWithGlobalFallback (   $context)
private

Various initialize methods used for fallback, which can be simplified in TYPO3 v11.0 Used to set $this->context. The first argument was $GLOBALS[TYPO3_CONF_VARS] (array) until TYPO3 v8, so no type hint possible.

Parameters
Context | array | null$context

Definition at line 661 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$context.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ initializeFrontendUserOrUpdateCHashArgument()

PageArguments TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initializeFrontendUserOrUpdateCHashArgument (   $cHashOrFrontendUser,
PageArguments  $pageArguments 
)
private

Since TYPO3 v10.0, the fifth constructor argument is expected to to be of Type FrontendUserAuthentication. However, up until TYPO3 v9.5 this argument was used to define the "cHash" GET/POST parameter. In order to ensure maximum compatibility, a deprecation is triggered if an old argument is still used, and PageArguments are updated accordingly, and returned.

Parameters
string | FrontendUserAuthentication | null$cHashOrFrontendUser
PageArguments$pageArguments
Returns
‪PageArguments

Definition at line 755 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$pageArguments, TYPO3\CMS\Core\Routing\PageArguments\getPageId(), and TYPO3\CMS\Core\Routing\PageArguments\getPageType().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ initializeLegacyMountPointArgument()

PageArguments TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initializeLegacyMountPointArgument ( ?string  $MP,
PageArguments  $pageArguments 
)
private

Since TYPO3 v10.0 the seventh constructor argument is not needed anymore, as all data is already provided by the given PageArguments object. However, if a specific MP parameter is given anyways, the PageArguments object is updated and returned.

Parameters
string | null$MP
PageArguments$pageArguments
Returns
‪PageArguments

Definition at line 783 of file TypoScriptFrontendController.php.

References $GLOBALS, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$MP, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$pageArguments, TYPO3\CMS\Core\Routing\PageArguments\getPageId(), and TYPO3\CMS\Core\Routing\PageArguments\getPageType().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ initializeSearchWordData()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initializeSearchWordData (   $searchWords)
protected

Fills the sWordList property and builds the regular expression in TSFE that can be used to split strings by the submitted search words.

Parameters
mixed$searchWords‪- usually an array, but we can't be sure (yet)
See also
‪sWordList
‪sWordRegEx

Definition at line 2779 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\preparePageContentGeneration().

◆ initializeSiteLanguageWithCompatibility()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initializeSiteLanguageWithCompatibility (   $siteLanguageOrType,
ServerRequestInterface  $request 
)
private

Until TYPO3 v10.0, the third argument of the constructor was given from GET/POST "type" to define the page type Since TYPO3 v10.0, this argument is requested to be of type SiteLanguage, which will be mandatory in TYPO3 v11.0. If no SiteLanguage object is given, this is fetched from the given request object.

Parameters
SiteLanguage | int | string | null$siteLanguageOrType
ServerRequestInterface$request

Definition at line 706 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ initializeSiteWithCompatibility()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initializeSiteWithCompatibility (   $siteOrId,
ServerRequestInterface  $request 
)
private

Second argument of the constructor. Until TYPO3 v10, this was the Page ID (int/string) but since TYPO3 v10.0 this can also be a SiteInterface object, which will be mandatory in TYPO3 v11.0. If no Site object is given, this is fetched from the given request object.

Parameters
SiteInterface | int | string$siteOrId
ServerRequestInterface$request

Definition at line 683 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ initPageRenderer()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initPageRenderer ( )
protected

◆ initUserGroups()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::initUserGroups ( )

Initializes the front-end user groups. Sets frontend.user aspect based on front-end user status.

Definition at line 844 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\fetch_the_id().

◆ INTincScript()

◆ INTincScript_loadJSCode()

◆ isAllowedLinkVarValue()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::isAllowedLinkVarValue ( string  $haystack,
string  $needle 
)
protected

Checks if the value defined in "config.linkVars" contains an allowed value. Otherwise, return FALSE which means the value will not be added to any links.

Parameters
string$haystack‪The string in which to find $needle
string$needle‪The string to find in $haystack
Returns
‪bool Returns TRUE if $needle matches or is found in $haystack

Definition at line 2410 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Core\Utility\MathUtility\canBeInterpretedAsInteger().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\calculateLinkVars().

◆ isBackendUserLoggedIn()

◆ isGeneratePage()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::isGeneratePage ( )

Returns TRUE if the page should be generated. That is if no URL handler is active and the cacheContentFlag is not set.

Returns
‪bool

Definition at line 2514 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$cacheContentFlag.

◆ isInPreviewMode()

◆ isINTincScript()

◆ isOutputting()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::isOutputting ( bool  $isCoreCall = false)

Determines if content should be outputted. Outputting content is done only if no URL handler is active and no hook disables the output.

Parameters
bool$isCoreCall‪if set to "true" no deprecation warning will be triggered, because TYPO3 keeps calling this method to keep backwards-compatibility
Returns
‪bool Returns TRUE if no redirect URL is set and no hook disables the output.
Deprecated:
‪will be removed in TYPO3 v11.0. Do not call this method anymore.

Definition at line 3145 of file TypoScriptFrontendController.php.

References $GLOBALS.

◆ isStaticCacheble()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::isStaticCacheble ( )

Reporting status whether we can send cache control headers for proxy caching or publishing to static files

Rules are: no_cache cannot be set: If it is, the page might contain dynamic content and should never be cached. There can be no USER_INT objects on the page ("isINTincScript()") because they implicitly indicate dynamic content There can be no logged in user because user sessions are based on a cookie and thereby does not offer client caching a chance to know if the user is logged in. Actually, there will be a reverse problem here; If a page will somehow change when a user is logged in he may not see it correctly if the non-login version sent a cache-header! So do NOT use cache headers in page sections where user logins change the page content. (unless using such as realurl to apply a prefix in case of login sections)

Returns
‪bool

Definition at line 3307 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isINTincScript(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isUserOrGroupSet().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getCacheHeaders().

◆ isUserOrGroupSet()

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::isUserOrGroupSet ( )

Checking if a user is logged in or a group constellation different from "0,-1"

Returns
‪bool TRUE if either a login user is found (array fe_user->user) OR if the gr_list is set to something else than '0,-1' (could be done even without a user being logged in!)

Definition at line 892 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineId(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isStaticCacheble().

◆ logDeprecatedTyposcript()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::logDeprecatedTyposcript (   $typoScriptProperty,
  $explanation = '' 
)

Logs access to deprecated TypoScript objects and properties.

Dumps message to the TypoScript message log (admin panel) and the TYPO3 deprecation log.

Parameters
string$typoScriptProperty‪Deprecated object or property
string$explanation‪Message or additional information

Definition at line 3403 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getTimeTracker(), and TYPO3\CMS\Core\TimeTracker\TimeTracker\setTSlogMessage().

◆ newCObj()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::newCObj ( )

Creates an instance of ContentObjectRenderer in $this->cObj This instance is used to start the rendering of the TypoScript template structure

See also
‪RequestHandler

Definition at line 3323 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\preparePageContentGeneration().

◆ populatePageDataFromCache()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::populatePageDataFromCache ( array  $cachedData)
protected

This method properly sets the values given from the pages cache into the corresponding TSFE variables. The counterpart is setPageCacheContent() where all relevant information is fetched. This also contains all data that could be cached, even for pages that are partially cached, as they have non-cacheable content still to be rendered.

See also
getFromCache()
setPageCacheContent()
Parameters
array$cachedData

Definition at line 1867 of file TypoScriptFrontendController.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getFromCache().

◆ preparePageContentGeneration()

◆ printTitle()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::printTitle ( string  $pageTitle,
bool  $noTitle = false,
bool  $showTitleFirst = false,
string  $pageTitleSeparator = '' 
)
protected

Compiles the content for the page <title> tag.

Parameters
string$pageTitle‪The input title string, typically the "title" field of a page's record.
bool$noTitle‪If set, then only the site title is outputted (from $this->setup['sitetitle'])
bool$showTitleFirst‪If set, then "sitetitle" and $title is swapped
string$pageTitleSeparator‪an alternative to the ": " as the separator between site title and page title
Returns
‪string The page title on the form "[sitetitle]: [input-title]". Not htmlspecialchar()'ed.
See also
generatePageTitle()

Definition at line 2903 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getWebsiteTitle().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\generatePageTitle().

◆ processContentForOutput()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::processContentForOutput ( bool  $isCoreCall = false)

Process the output before it's actually outputted.

This includes substituting the "username" comment. Works on $this->content.

Parameters
bool$isCoreCall‪if set to "true" no deprecation warning will be triggered, because TYPO3 keeps calling this method to keep backwards-compatibility
Deprecated:
‪this method will be removed in TYPO3 v11. Use a PSR-15 middleware for processing content.

Definition at line 3172 of file TypoScriptFrontendController.php.

References $GLOBALS.

◆ processNonCacheableContentPartsAndSubstituteContentMarkers()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::processNonCacheableContentPartsAndSubstituteContentMarkers ( array  $nonCacheableData)
protected

Processes the INTinclude-scripts and substitute in content.

Takes $this->content, and splits the content by and then puts the content back together.

Parameters
array$nonCacheableData‪$GLOBALS['TSFE']->config['INTincScript'] or part of it
See also
INTincScript()

Definition at line 3019 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\convOutputCharset(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getTimeTracker().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\recursivelyReplaceIntPlaceholdersInContent().

◆ realPageCacheContent()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::realPageCacheContent ( )
protected

◆ recursivelyReplaceIntPlaceholdersInContent()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::recursivelyReplaceIntPlaceholdersInContent ( )
protected

Replaces INT placeholders (COA_INT and USER_INT) in $this->content In case the replacement adds additional placeholders, it loops until no new placeholders are found any more.

Definition at line 2998 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\processNonCacheableContentPartsAndSubstituteContentMarkers().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript().

◆ releaseLock()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::releaseLock (   $type)
protected

◆ releaseLocks()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::releaseLocks ( )

◆ reqCHash()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::reqCHash ( )

Will disable caching if the cHash value was not set when having dynamic arguments in GET query parameters. This function should be called to check the existence of "&cHash" whenever a plugin generating cacheable output is using extra GET variables. If there is a cHash value the validation of it automatically takes place in makeCacheHash() (see above)

Deprecated:
‪since TYPO3 v10.2, will be removed in TYPO3 v11. The PSR-15 middleware PageArgumentValidator is already taking care of this.

Definition at line 1701 of file TypoScriptFrontendController.php.

References $GLOBALS, TYPO3\CMS\Core\Utility\HttpUtility\buildQueryString(), TYPO3\CMS\Frontend\Page\PageAccessFailureReasons\CACHEHASH_EMPTY, TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\disableCache(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getTimeTracker(), and TYPO3\CMS\Core\TimeTracker\TimeTracker\setTSlogMessage().

◆ resolveContentPid()

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::resolveContentPid ( ServerRequestInterface  $request)
protected

Check the value of "content_from_pid" of the current page record, and see if the current request should actually show content from another page.

By using $TSFE->getPageAndRootline() on the cloned object, all rootline restrictions (extendToSubPages) are evaluated as well.

Parameters
ServerRequestInterface$request
Returns
‪int the current page ID or another one if resolved properly - usually set to $this->contentPid

Definition at line 2687 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$id.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\preparePageContentGeneration().

◆ resolveTranslatedPageId()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::resolveTranslatedPageId ( )
protected

If $this->id contains a translated page record, this needs to be resolved to the default language in order for all rootline functionality and access restrictions to be in place further on.

Additionally, if a translated page is found, LanguageAspect is set as well.

Definition at line 1437 of file TypoScriptFrontendController.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPageAndRootline().

◆ set_cache_timeout_default()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::set_cache_timeout_default (   $seconds)

Sets the cache-timeout in seconds

Parameters
int$seconds‪Cache-timeout in seconds

Definition at line 3550 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getConfigArray().

◆ set_no_cache()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::set_no_cache (   $reason = '',
  $internal = false 
)

◆ setAbsRefPrefix()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setAbsRefPrefix ( )

◆ setContentType()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setContentType (   $contentType)
Parameters
string$contentType

Should only be used by TYPO3 core for now

Definition at line 822 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$contentType.

◆ setJS()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setJS (   $key,
  $content = '' 
)

Sets JavaScript code in the additionalJavaScript array

Parameters
string$key‪is the key in the array, for num-key let the value be empty. Note reserved key: 'openPic'
string$content‪is the content if you want any
See also
ContentObjectRenderer::imageLinkWrap()

only used by TYPO3 Core, use PageRenderer or AssetCollector API instead.

Definition at line 3473 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$content.

◆ setOutputLanguage()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setOutputLanguage ( )
protected

Sets all internal measures what language the page should be rendered. This is not for records, but rather the HTML / charset and the locallang labels

Definition at line 3621 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Core\Localization\LanguageService\createFromSiteLanguage().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\__construct().

◆ setPageArguments()

◆ setPageCacheContent()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setPageCacheContent (   $content,
  $data,
  $expirationTstamp 
)
protected

◆ setRegisterValueForSysLastChanged()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setRegisterValueForSysLastChanged ( array  $page)
protected

Set the SYS_LASTCHANGED register value, is also called when a translated page is in use, so the register reflects the state of the translated page, not the page in the default language.

Parameters
array$page

Definition at line 2621 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$page.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\fetch_the_id(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\settingLanguage().

◆ setSysLastChanged()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::setSysLastChanged ( )
protected

Sets sys last changed Setting the SYS_LASTCHANGED value in the pagerecord: This value will thus be set to the highest tstamp of records rendered on the page. This includes all records with no regard to hidden records, userprotection and so on.

See also
ContentObjectRenderer::lastChanged()

Definition at line 2595 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\$id, and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\doWorkspacePreview().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\generatePage_postProcessing().

◆ settingLanguage()

◆ settingLocale()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::settingLocale ( )

◆ sL()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::sL (   $input)

Split Label function for front-end applications.

Parameters
string$input‪Key string. Accepts the "LLL:" prefix.
Returns
‪string Label value, if any.

Definition at line 3612 of file TypoScriptFrontendController.php.

◆ splitLinkVarsString()

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::splitLinkVarsString ( string  $string)
protected

Split the link vars string by "," but not if the "," is inside of braces

Parameters
string$string
Returns
‪array

Definition at line 2387 of file TypoScriptFrontendController.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\calculateLinkVars().

◆ uniqueHash()

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::uniqueHash (   $str = '')

Returns a unique md5 hash. There is no special magic in this, the only point is that you don't have to call md5(uniqid()) which is slow and by this you are sure to get a unique string each time in a little faster way.

Parameters
string$str‪Some string to include in what is hashed. Not significant at all.
Returns
‪string MD5 hash of ->uniqueString, input string and uniqueCounter

Definition at line 3492 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript_loadJSCode(), and TYPO3\CMS\Frontend\ContentObject\ContentObjectArrayInternalContentObject\render().

◆ updateRootLinesWithTranslations()

TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::updateRootLinesWithTranslations ( )
protected

Updating content of the two rootLines IF the language key is set!

Definition at line 2264 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\settingLanguage().

◆ whichWorkspace()

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::whichWorkspace ( )

Returns the uid of the current workspace

Returns
‪int returns workspace integer for which workspace is being preview. 0 if none (= live workspace).

Definition at line 3429 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\applyPreviewSettings(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineIdIsHiddenPage(), and TYPO3\CMS\Workspaces\Middleware\WorkspacePreview\renderPreviewInfo().

Member Data Documentation

◆ $absRefPrefix

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$absRefPrefix = ''

◆ $accessKey

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$accessKey = array( )

Used by class \TYPO3\CMS\Frontend\ContentObject\Menu\AbstractMenuContentObject to keep track of access-keys.

Definition at line 494 of file TypoScriptFrontendController.php.

◆ $additionalCSS

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$additionalCSS = array( )

Used to accumulate additional Style code. Works like additionalHeaderData.

only used by TYPO3 Core, use AssetCollector or PageRenderer to add CSS

Definition at line 365 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript_loadJSCode().

◆ $additionalFooterData

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$additionalFooterData = array( )

Used to accumulate additional HTML-code for the footer-section of the template

Definition at line 350 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript_loadJSCode().

◆ $additionalHeaderData

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$additionalHeaderData = array( )

Eg. insert JS-functions in this array ($additionalHeaderData) to include them once. Use associative keys.

Keys in use:

used to accumulate additional HTML-code for the header-section, <head>...</head>. Insert either associative keys (like additionalHeaderData['myStyleSheet'], see reserved keys above) or num-keys (like additionalHeaderData[] = '...')

Definition at line 345 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript_loadJSCode().

◆ $additionalJavaScript

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$additionalJavaScript = array( )

Used to accumulate additional JavaScript-code. Works like additionalHeaderData. Reserved keys at 'openPic' and 'mouseOver'

only used by TYPO3 Core, use AssetCollector or PageRenderer to add JavaScript

Definition at line 358 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript_loadJSCode().

◆ $all

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$all = array( )

Used by template fetching system. This array is an identification of the template. If $this->all is empty it's because the template-data is not cached, which it must be.

Definition at line 283 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\createHashBase().

◆ $applicationData

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$applicationData = array( )

'Global' Storage for various applications. Keys should be 'tx_'.extKey for extensions.

Definition at line 458 of file TypoScriptFrontendController.php.

◆ $ATagParams

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$ATagParams = ''

-tag parameters

Definition at line 411 of file TypoScriptFrontendController.php.

◆ $baseUrl

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$baseUrl = ''

The base URL set for the page header.

Definition at line 532 of file TypoScriptFrontendController.php.

◆ $cacheContentFlag

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cacheContentFlag = false
protected

Set internally if cached content is fetched from the database.

Definition at line 263 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\isGeneratePage().

◆ $cacheExpires

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cacheExpires = 0
protected

Set to the expire time of cached content

Definition at line 269 of file TypoScriptFrontendController.php.

◆ $cacheTimeOutDefault

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cacheTimeOutDefault = 86400
protected

Is set to the time-to-live time of cached pages. Default is 60*60*24, which is 24 hours.

Definition at line 256 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\get_cache_timeout().

◆ $cHash

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cHash = ''
protected

The submitted cHash

Deprecated:
‪will be removed in TYPO3 v11.0. don't use it anymore, as this is now within the PageArguments property.

Definition at line 132 of file TypoScriptFrontendController.php.

◆ $cHash_array

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cHash_array = array( )
protected

The array which cHash_calc is based on, see PageArgumentValidator class.

Deprecated:
‪will be removed in TYPO3 v11.0. don't use it anymore, see getRelevantParametersForCachingFromPageArguments()

Definition at line 325 of file TypoScriptFrontendController.php.

◆ $cObj

ContentObjectRenderer TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cObj

Page content render object

Definition at line 538 of file TypoScriptFrontendController.php.

◆ $cObjectDepthCounter

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$cObjectDepthCounter = 50

Checking that the function is not called eternally. This is done by interrupting at a depth of 50

Definition at line 474 of file TypoScriptFrontendController.php.

◆ $config

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$config = array( )

"CONFIG" object from TypoScript. Array generated based on the TypoScript configuration of the current page. Saved with the cached pages.

Definition at line 243 of file TypoScriptFrontendController.php.

◆ $content

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$content = ''

◆ $contentPid

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$contentPid = 0

This will normally point to the same value as id, but can be changed to point to another page from which content will then be displayed instead.

Definition at line 159 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setPageCacheContent().

◆ $contentType

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$contentType = 'text/html'
protected

Content type HTTP header being sent in the request.

Todo:
‪Ticket: #63642 Should be refactored to a request/response model later

Should only be used by TYPO3 core for now

Definition at line 583 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setContentType().

◆ $context

Context TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$context
protected

The context for keeping the current state, mostly related to current page information, backend user / frontend user access, workspaceId

Definition at line 606 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\determineIdIsHiddenPage(), TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getContext(), and TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\initializeContextWithGlobalFallback().

◆ $currentRecord

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$currentRecord = ''

This is set to the [table]:[uid] of the latest record rendered. Note that class ContentObjectRenderer has an equal value, but that is pointing to the record delivered in the $data-array of the ContentObjectRenderer instance, if the cObjects CONTENT or RECORD created that instance

Definition at line 488 of file TypoScriptFrontendController.php.

◆ $deprecatedPublicProperties

string [] TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$deprecatedPublicProperties
private
Initial value:
= array(
'imagesOnPage' => 'Using TSFE->imagesOnPage is deprecated and will no longer work with TYPO3 v11.0. Use AssetCollector()->getMedia() instead.',
'lastImageInfo' => 'Using TSFE->lastImageInfo is deprecated and will no longer work with TYPO3 v11.0.'
)

Definition at line 104 of file TypoScriptFrontendController.php.

◆ $displayEditIcons

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$displayEditIcons = ''

If set, edit icons are rendered aside content records. Must be set only if the ->beUserLogin flag is set and set_no_cache() must be called as well.

Definition at line 439 of file TypoScriptFrontendController.php.

◆ $displayFieldEditIcons

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$displayFieldEditIcons = ''

If set, edit icons are rendered aside individual fields of content. Must be set only if the ->beUserLogin flag is set and set_no_cache() must be called as well.

Definition at line 446 of file TypoScriptFrontendController.php.

◆ $divSection

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$divSection = ''

Used to accumulate DHTML-layers.

Deprecated:
‪since TYPO3 v10.2, will be removed in TYPO3 v11, use custom USER_INT objects instead.

Definition at line 381 of file TypoScriptFrontendController.php.

◆ $domainStartPage

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$domainStartPage = 0
protected

Domain start page

Deprecated:
‪will be removed in TYPO3 v11.0. don't use it anymore, as this is now within the Site. see $this->site->getRootPageId()

Definition at line 195 of file TypoScriptFrontendController.php.

◆ $extTarget

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$extTarget = ''

Default external target

Definition at line 391 of file TypoScriptFrontendController.php.

◆ $fe_user

FrontendUserAuthentication string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$fe_user = ''

The frontend user

Definition at line 211 of file TypoScriptFrontendController.php.

◆ $fePreview

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$fePreview = 0
protected

Flag indication that preview is active. This is based on the login of a backend user and whether the backend user has read access to the current page.

Deprecated:
‪will be removed in TYPO3 v11.0. don't use it anymore, as this is now within PreviewAspect

Definition at line 231 of file TypoScriptFrontendController.php.

◆ $fileTarget

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$fileTarget = ''

Default file link target

Definition at line 396 of file TypoScriptFrontendController.php.

◆ $forceTemplateParsing

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$forceTemplateParsing = false
private

Passed to TypoScript template class and tells it to force template rendering

Deprecated:

Definition at line 318 of file TypoScriptFrontendController.php.

◆ $id

◆ $imagesOnPage

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$imagesOnPage = array( )
private

Numerical array where image filenames are added if they are referenced in the rendered document. This includes only TYPO3 generated/inserted images.

Deprecated:

Definition at line 501 of file TypoScriptFrontendController.php.

◆ $indexedDocTitle

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$indexedDocTitle = ''

This value will be used as the title for the page in the indexer (if indexing happens)

only used by TYPO3 Core, use PageTitle API instead.

Definition at line 527 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setPageCacheContent().

◆ $inlineJS

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$inlineJS

only used by TYPO3 Core, use AssetCollector or PageRenderer to add inline JavaScript

Definition at line 375 of file TypoScriptFrontendController.php.

◆ $intTarget

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$intTarget = ''

Default internal target

Definition at line 386 of file TypoScriptFrontendController.php.

◆ $isClientCachable

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$isClientCachable = false
protected

Set if cache headers allowing caching are sent.

Definition at line 275 of file TypoScriptFrontendController.php.

◆ $JSCode

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$JSCode

only used by TYPO3 Core, use AssetCollector or PageRenderer to add inline JavaScript

Definition at line 370 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\INTincScript_loadJSCode().

◆ $language

SiteLanguage TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$language
protected

◆ $languageService

LanguageService TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$languageService
protected

Internal calculations for labels

Definition at line 556 of file TypoScriptFrontendController.php.

◆ $lastImageInfo

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$lastImageInfo = array( )
private

Is set in ContentObjectRenderer->cImage() function to the info-array of the most recent rendered image. The information is used in ImageTextContentObject

Deprecated:

Definition at line 508 of file TypoScriptFrontendController.php.

◆ $linkVars

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$linkVars = ''

A string prepared for insertion in all links on the page as url-parameters. Based on configuration in TypoScript where you defined which GET_VARS you would like to pass on.

Definition at line 433 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\calculateLinkVars().

◆ $locks

LockingStrategyInterface [][] TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$locks = array( )
protected

Definition at line 560 of file TypoScriptFrontendController.php.

◆ $loginAllowedInBranch

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$loginAllowedInBranch = true
protected

Shows whether logins are allowed in branch

Definition at line 216 of file TypoScriptFrontendController.php.

◆ $loginAllowedInBranch_mode

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$loginAllowedInBranch_mode = ''
protected

Shows specific mode (all or groups)

Definition at line 222 of file TypoScriptFrontendController.php.

◆ $metaCharset

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$metaCharset = 'utf-8'

Output charset of the websites content. This is the charset found in the header, meta tag etc. If different than utf-8 a conversion happens before output to browser. Defaults to utf-8.

Definition at line 550 of file TypoScriptFrontendController.php.

◆ $MP

◆ $newHash

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$newHash = ''

This hash is unique to the template, the $this->id and $this->type vars and the list of groups. Used to get and later store the cached data

Definition at line 303 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\setPageCacheContent().

◆ $no_cache

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$no_cache = false

Page will not be cached. Write only TRUE. Never clear value (some other code might have reasons to set it TRUE).

Definition at line 143 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\generatePage_preProcessing().

◆ $no_cacheBeforePageGen

bool TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$no_cacheBeforePageGen = false
protected

This flag is set before the page is generated IF $this->no_cache is set. If this flag is set after the page content was generated, $this->no_cache is forced to be set. This is done in order to make sure that PHP code from Plugins / USER scripts does not falsely clear the no_cache flag.

Definition at line 312 of file TypoScriptFrontendController.php.

◆ $originalMountPointPage

array null TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$originalMountPointPage
protected

Gets set when we are processing a page of type mounpoint with enabled overlay in getPageAndRootline() Used later in checkPageForMountpointRedirect() to determine the final target URL where the user should be redirected to.

Definition at line 167 of file TypoScriptFrontendController.php.

◆ $originalShortcutPage

array null TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$originalShortcutPage
protected

Gets set when we are processing a page of type shortcut in the early stages of the request when we do not know about languages yet, used later in the request to determine the correct shortcut in case a translation changes the shortcut target

See also
checkTranslatedShortcut()

Definition at line 176 of file TypoScriptFrontendController.php.

◆ $page

◆ $pageAccessFailureHistory

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pageAccessFailureHistory = array( )
protected

Array containing a history of why a requested page was not accessible.

Definition at line 200 of file TypoScriptFrontendController.php.

◆ $pageArguments

◆ $pageCache

TYPO3 CMS Core Cache Frontend FrontendInterface TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pageCache
protected

The page cache object, use this to save pages to the cache and to retrieve them again

Definition at line 571 of file TypoScriptFrontendController.php.

◆ $pageCacheTags

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pageCacheTags = array( )
protected

◆ $pageNotFound

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pageNotFound = 0

Is set to 1 if a pageNotFound handler could have been called.

Definition at line 188 of file TypoScriptFrontendController.php.

◆ $pageRenderer

PageRenderer TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pageRenderer
protected

◆ $pagesTSconfig

array string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pagesTSconfig = ''
protected

May be set to the pagesTSconfig

Definition at line 331 of file TypoScriptFrontendController.php.

Referenced by TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController\getPagesTSconfig().

◆ $pSetup

array string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$pSetup = ''

TypoScript configuration of the page-object pointed to by sPre. $this->tmpl->setup[$this->sPre.'.']

should only be used by TYPO3 Core

Definition at line 296 of file TypoScriptFrontendController.php.

◆ $recordRegister

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$recordRegister = array( )

Used by RecordContentObject and ContentContentObject to ensure the a records is NOT rendered twice through it!

Definition at line 480 of file TypoScriptFrontendController.php.

◆ $register

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$register = array( )

Definition at line 462 of file TypoScriptFrontendController.php.

◆ $registerStack

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$registerStack = array( )

Stack used for storing array and retrieving register arrays (see LOAD_REGISTER and RESTORE_REGISTER)

Definition at line 468 of file TypoScriptFrontendController.php.

◆ $requestedId

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$requestedId
protected

Originally requested id from the initial $_GET variable

Definition at line 599 of file TypoScriptFrontendController.php.

◆ $rootLine

array TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$rootLine = array( )

The rootLine (all the way to tree root, not only the current site!)

Definition at line 148 of file TypoScriptFrontendController.php.

◆ $simUserGroup

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$simUserGroup = 0

Value that contains the simulated usergroup if any

only to be used in AdminPanel, and within TYPO3 Core

Definition at line 237 of file TypoScriptFrontendController.php.

◆ $site

Site TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$site
protected

◆ $spamProtectEmailAddresses

string int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$spamProtectEmailAddresses = 0

If set, typolink() function encrypts email addresses.

Definition at line 401 of file TypoScriptFrontendController.php.

◆ $sPre

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$sPre = ''

Toplevel - objArrayName, eg 'page'

should only be used by TYPO3 Core

Definition at line 289 of file TypoScriptFrontendController.php.

◆ $sWordList

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$sWordList = ''

Is set to the incoming array sword_list in case of a page-view jumped to from a search-result.

Definition at line 426 of file TypoScriptFrontendController.php.

◆ $sWordRegEx

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$sWordRegEx = ''

Search word regex, calculated if there has been search-words send. This is used to mark up the found search words on a page when jumped to from a link in a search-result.

Definition at line 419 of file TypoScriptFrontendController.php.

◆ $sys_language_isocode

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$sys_language_isocode = ''
protected

Is set to the iso code of the current language

Deprecated:
‪will be removed in TYPO3 v11.0. don't use it anymore, as this is now within SiteLanguage->getTwoLetterIsoCode()

Definition at line 452 of file TypoScriptFrontendController.php.

◆ $sys_page

PageRepository string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$sys_page = ''

sys_page-object, pagefunctions

Definition at line 182 of file TypoScriptFrontendController.php.

◆ $tmpl

TemplateService TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$tmpl

The TypoScript template object. Used to parse the TypoScript template

Definition at line 249 of file TypoScriptFrontendController.php.

◆ $type

◆ $uniqueCounter

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$uniqueCounter = 0
protected

Used to generate page-unique keys. Point is that uniqid() functions is very slow, so a unikey key is made based on this, see function uniqueHash()

Definition at line 515 of file TypoScriptFrontendController.php.

◆ $uniqueString

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$uniqueString = ''
protected

Definition at line 520 of file TypoScriptFrontendController.php.

◆ $xhtmlDoctype

string TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$xhtmlDoctype = ''

Doctype to use

Definition at line 589 of file TypoScriptFrontendController.php.

◆ $xhtmlVersion

int TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::$xhtmlVersion

Definition at line 593 of file TypoScriptFrontendController.php.