‪TYPO3CMS  11.5
TYPO3\CMS\Info\Controller\PageInformationController Class Reference

Public Member Functions

 __construct (IconFactory $iconFactory, UriBuilder $uriBuilder)
 
 init (InfoModuleController $pObj, ServerRequestInterface $request)
 
string main (ServerRequestInterface $request)
 

Protected Member Functions

array modMenu ()
 
string cleanTableNames ()
 
 fillFieldConfiguration (int $pageId)
 
string getTable_pages ($id, int $depth, ServerRequestInterface $request)
 
array getPageRecordsRecursive (int $pid, int $depth, string $iconPrefix='', array $rows=[])
 
string pages_drawItem ($row, $fieldArr, ServerRequestInterface $request)
 
string getIcon ($row)
 
string getPagesTableFieldValue ($field, array $row)
 
int numberOfRecords ($table, $pid)
 
string addElement ($data)
 
BackendUserAuthentication getBackendUser ()
 
LanguageService null getLanguageService ()
 
 getBackendLayouts (array $row, string $field)
 
 resolveBackendLayoutValue (?string $layoutValue, string $field, array $row)
 

Protected Attributes

array $fieldConfiguration = array( )
 
 $id
 
InfoModuleController $pObj
 
IconFactory $iconFactory
 
UriBuilder $uriBuilder
 
BackendLayoutView $backendLayoutView = null
 
array $fieldArray
 
array $addElement_tdCssClass = array( )
 

Detailed Description

Class for displaying page information (records, page record properties) in Web -> Info

This class is a specific Backend controller implementation and is not part of the TYPO3's Core API.

Definition at line 39 of file PageInformationController.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Info\Controller\PageInformationController::__construct ( IconFactory  $iconFactory,
UriBuilder  $uriBuilder 
)

Member Function Documentation

◆ addElement()

string TYPO3\CMS\Info\Controller\PageInformationController::addElement (   $data)
protected

Returns a table-row with the content from the fields in the input data array. OBS: $this->fieldArray MUST be set! (represents the list of fields to display)

Parameters
array$data‪Is the data array, record with the fields. Notice: These fields are (currently) NOT htmlspecialchar'ed before being wrapped in

-tags

Returns
‪string HTML content for the table row

Definition at line 554 of file PageInformationController.php.

References TYPO3\CMS\Info\Controller\PageInformationController\$fieldArray, and $fields.

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\getTable_pages(), and TYPO3\CMS\Info\Controller\PageInformationController\pages_drawItem().

◆ cleanTableNames()

string TYPO3\CMS\Info\Controller\PageInformationController::cleanTableNames ( )
protected

Function, which returns all tables to which the user has access. Also a set of standard tables (pages, sys_filemounts, etc...) are filtered out. So what is left is basically all tables which makes sense to list content from.

Returns
‪string

Definition at line 163 of file PageInformationController.php.

References $GLOBALS, and TYPO3\CMS\Info\Controller\PageInformationController\getBackendUser().

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\fillFieldConfiguration().

◆ fillFieldConfiguration()

TYPO3\CMS\Info\Controller\PageInformationController::fillFieldConfiguration ( int  $pageId)
protected

◆ getBackendLayouts()

TYPO3\CMS\Info\Controller\PageInformationController::getBackendLayouts ( array  $row,
string  $field 
)
protected

◆ getBackendUser()

◆ getIcon()

string TYPO3\CMS\Info\Controller\PageInformationController::getIcon (   $row)
protected

Creates the icon image tag for the page and wraps it in a link which will trigger the click menu.

Parameters
array$row‪Record array
Returns
‪string HTML for the icon

Definition at line 494 of file PageInformationController.php.

References TYPO3\CMS\Info\Controller\PageInformationController\getBackendUser(), and TYPO3\CMS\Core\Imaging\Icon\SIZE_SMALL.

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\pages_drawItem().

◆ getLanguageService()

◆ getPageRecordsRecursive()

array TYPO3\CMS\Info\Controller\PageInformationController::getPageRecordsRecursive ( int  $pid,
int  $depth,
string  $iconPrefix = '',
array  $rows = [] 
)
protected

Adds pages-rows to an array, selecting recursively in the page tree.

Parameters
int$pid‪Starting page id to select from
string$iconPrefix‪Prefix for icon code.
int$depth‪Depth (decreasing)
array$rows‪Array which will accumulate page rows
Returns
‪array $rows with added rows.

Definition at line 333 of file PageInformationController.php.

References $GLOBALS, TYPO3\CMS\Info\Controller\PageInformationController\getBackendUser(), TYPO3\CMS\Core\Type\Bitmask\Permission\PAGE_SHOW, and TYPO3\CMS\Core\Database\Connection\PARAM_INT.

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\getTable_pages().

◆ getPagesTableFieldValue()

string TYPO3\CMS\Info\Controller\PageInformationController::getPagesTableFieldValue (   $field,
array  $row 
)
protected

Returns the HTML code for rendering a field in the pages table. The row value is processed to a human readable form and the result is parsed through htmlspecialchars().

Parameters
string$field‪The name of the field of which the value should be rendered.
array$row‪The pages table row as an associative array.
Returns
‪string The rendered table field value.

Definition at line 513 of file PageInformationController.php.

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\pages_drawItem(), and TYPO3\CMS\Info\Controller\PageInformationController\resolveBackendLayoutValue().

◆ getTable_pages()

◆ init()

TYPO3\CMS\Info\Controller\PageInformationController::init ( InfoModuleController  $pObj,
ServerRequestInterface  $request 
)

Init, called from parent object

Parameters
InfoModuleController$pObj‪A reference to the parent (calling) object
ServerRequestInterface$request

Definition at line 80 of file PageInformationController.php.

References TYPO3\CMS\Info\Controller\PageInformationController\$pObj.

◆ main()

string TYPO3\CMS\Info\Controller\PageInformationController::main ( ServerRequestInterface  $request)

Main, called from parent object

Parameters
ServerRequestInterface$request
Returns
‪string Output HTML for the module.

Definition at line 94 of file PageInformationController.php.

References $GLOBALS, TYPO3\CMS\Info\Controller\PageInformationController\getLanguageService(), and TYPO3\CMS\Info\Controller\PageInformationController\getTable_pages().

◆ modMenu()

array TYPO3\CMS\Info\Controller\PageInformationController::modMenu ( )
protected

◆ numberOfRecords()

int TYPO3\CMS\Info\Controller\PageInformationController::numberOfRecords (   $table,
  $pid 
)
protected

Counts and returns the number of records on the page with $pid

Parameters
string$table‪Table name
int$pid‪Page id
Returns
‪int Number of records.

Definition at line 525 of file PageInformationController.php.

References $GLOBALS, TYPO3\CMS\Info\Controller\PageInformationController\getBackendUser(), and TYPO3\CMS\Core\Database\Connection\PARAM_INT.

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\pages_drawItem().

◆ pages_drawItem()

◆ resolveBackendLayoutValue()

TYPO3\CMS\Info\Controller\PageInformationController::resolveBackendLayoutValue ( ?string  $layoutValue,
string  $field,
array  $row 
)
protected

Member Data Documentation

◆ $addElement_tdCssClass

array TYPO3\CMS\Info\Controller\PageInformationController::$addElement_tdCssClass = array( )
protected

Keys are fieldnames and values are td-css-classes to add in addElement();

Definition at line 66 of file PageInformationController.php.

◆ $backendLayoutView

BackendLayoutView TYPO3\CMS\Info\Controller\PageInformationController::$backendLayoutView = null
protected

Definition at line 56 of file PageInformationController.php.

◆ $fieldArray

array TYPO3\CMS\Info\Controller\PageInformationController::$fieldArray
protected

◆ $fieldConfiguration

array TYPO3\CMS\Info\Controller\PageInformationController::$fieldConfiguration = array( )
protected

Definition at line 43 of file PageInformationController.php.

◆ $iconFactory

IconFactory TYPO3\CMS\Info\Controller\PageInformationController::$iconFactory
protected

◆ $id

TYPO3\CMS\Info\Controller\PageInformationController::$id
protected

◆ $pObj

InfoModuleController TYPO3\CMS\Info\Controller\PageInformationController::$pObj
protected

Contains a reference to the parent calling object

Definition at line 52 of file PageInformationController.php.

Referenced by TYPO3\CMS\Info\Controller\PageInformationController\init().

◆ $uriBuilder

UriBuilder TYPO3\CMS\Info\Controller\PageInformationController::$uriBuilder
protected