‪TYPO3CMS  11.5
TYPO3\CMS\Backend\Middleware\SiteResolver Class Reference
Inheritance diagram for TYPO3\CMS\Backend\Middleware\SiteResolver:

Public Member Functions

 __construct (SiteMatcher $siteMatcher)
 
ResponseInterface process (ServerRequestInterface $request, RequestHandlerInterface $handler)
 

Protected Attributes

SiteMatcher $siteMatcher
 

Detailed Description

Usually called after the route object is resolved, however, this is not possible yet as this happens within the RequestHandler/RouteDispatcher right now and should go away.

This middleware checks for a "id" parameter. If present, it adds a site information to this page ID.

Very useful for all "Web" related modules to resolve all available languages for a site.

Definition at line 36 of file SiteResolver.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Backend\Middleware\SiteResolver::__construct ( SiteMatcher  $siteMatcher)

Member Function Documentation

◆ process()

ResponseInterface TYPO3\CMS\Backend\Middleware\SiteResolver::process ( ServerRequestInterface  $request,
RequestHandlerInterface  $handler 
)

Resolve the site information by checking the page ID ("id" parameter) which is typically used in BE modules of type "web".

Parameters
ServerRequestInterface$request
RequestHandlerInterface$handler
Returns
‪ResponseInterface

Definition at line 55 of file SiteResolver.php.

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

Member Data Documentation

◆ $siteMatcher

SiteMatcher TYPO3\CMS\Backend\Middleware\SiteResolver::$siteMatcher
protected