TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Backend\Controller\BackendController Class Reference
Inheritance diagram for TYPO3\CMS\Backend\Controller\BackendController:
TYPO3backend

Public Member Functions

 getPageRenderer ()
 
 __construct ()
 
 render ()
 
 addJavascript ($javascript)
 
 addJavascriptFile ($javascriptFile)
 
 addCss ($css)
 
 addCssFile ($cssFileName, $cssFile)
 
 addToolbarItem ($toolbarItemName, $toolbarItemClassName)
 

Protected Member Functions

 initializeCoreToolbarItems ()
 
 loadResourcesForRegisteredNavigationComponents ()
 
 renderToolbar ()
 
 getLoggedInUserLabel ()
 
 getLocalLangFileName ()
 
 generateLocalLang ()
 
 generateJavascript ()
 
 handlePageEditing ()
 
 setStartupModule ()
 
 executeHook ($identifier, array $hookConfiguration=array())
 

Protected Attributes

 $content
 
 $css
 
 $cssFiles
 
 $js
 
 $jsFiles
 
 $jsFilesAfterInline
 
 $toolbarItems
 
 $menuWidth
 
 $debug
 
 $moduleLoader
 
 $moduleMenu
 
 $pageRenderer
 

Private Attributes

 $menuWidthDefault = 190
 

Detailed Description

Class for rendering the TYPO3 backend version 4.2+

Author
Ingo Renner ingo@.nosp@m.typo.nosp@m.3.org

Definition at line 26 of file BackendController.php.

Constructor & Destructor Documentation

◆ __construct()

Member Function Documentation

◆ addCss()

TYPO3\CMS\Backend\Controller\BackendController::addCss (   $css)

Adds a css snippet to the backend

Parameters
string$cssCss snippet
Returns
void

Definition at line 659 of file BackendController.php.

◆ addCssFile()

TYPO3\CMS\Backend\Controller\BackendController::addCssFile (   $cssFileName,
  $cssFile 
)

Adds a css file to the backend after it has been checked that it exists

Parameters
string$cssFileNameThe css file's name with out the .css ending
string$cssFileCss file reference
Returns
boolean TRUE if the css file was added, FALSE otherwise

Definition at line 673 of file BackendController.php.

◆ addJavascript()

TYPO3\CMS\Backend\Controller\BackendController::addJavascript (   $javascript)

Adds a javascript snippet to the backend

Parameters
string$javascriptJavascript snippet
Returns
void
Exceptions

Definition at line 629 of file BackendController.php.

◆ addJavascriptFile()

TYPO3\CMS\Backend\Controller\BackendController::addJavascriptFile (   $javascriptFile)

Adds a javscript file to the backend after it has been checked that it exists

Parameters
string$javascriptFileJavascript file reference
Returns
boolean TRUE if the javascript file was successfully added, FALSE otherwise

Definition at line 643 of file BackendController.php.

◆ addToolbarItem()

TYPO3\CMS\Backend\Controller\BackendController::addToolbarItem (   $toolbarItemName,
  $toolbarItemClassName 
)

Adds an item to the toolbar, the class file for the toolbar item must be loaded at this point

Parameters
string$toolbarItemNameToolbar item name, f.e. tx_toolbarExtension_coolItem
string$toolbarItemClassNameToolbar item class name, f.e. tx_toolbarExtension_coolItem
Returns
void
Exceptions

Definition at line 690 of file BackendController.php.

◆ executeHook()

TYPO3\CMS\Backend\Controller\BackendController::executeHook (   $identifier,
array  $hookConfiguration = array() 
)
protected

Executes defined hooks functions for the given identifier.

These hook identifiers are valid:

  • constructPostProcess
  • renderPreProcess
  • renderPostProcess
Parameters
string$identifierSpecific hook identifier
array$hookConfigurationAdditional configuration passed to hook functions
Returns
void

Definition at line 714 of file BackendController.php.

References $GLOBALS, and TYPO3\CMS\Core\Utility\GeneralUtility\callUserFunction().

Referenced by TYPO3\CMS\Backend\Controller\BackendController\__construct(), and TYPO3\CMS\Backend\Controller\BackendController\render().

◆ generateJavascript()

◆ generateLocalLang()

TYPO3\CMS\Backend\Controller\BackendController::generateLocalLang ( )
protected

Reads labels required in JavaScript code from the localization system and returns them as JSON array in TYPO3.LLL.

Returns
string JavaScript code containing the LLL labels in TYPO3.LLL

Definition at line 359 of file BackendController.php.

References $GLOBALS.

Referenced by TYPO3\CMS\Backend\Controller\BackendController\getLocalLangFileName().

◆ getLocalLangFileName()

TYPO3\CMS\Backend\Controller\BackendController::getLocalLangFileName ( )
protected

Returns the file name to the LLL JavaScript, containing the localized labels, which can be used in JavaScript code.

Returns
string File name of the JS file, relative to TYPO3_mainDir

Definition at line 341 of file BackendController.php.

References TYPO3\CMS\Backend\Controller\BackendController\generateLocalLang(), and TYPO3\CMS\Core\Utility\GeneralUtility\writeFileToTypo3tempDir().

Referenced by TYPO3\CMS\Backend\Controller\BackendController\__construct().

◆ getLoggedInUserLabel()

TYPO3\CMS\Backend\Controller\BackendController::getLoggedInUserLabel ( )
protected

Gets the label of the BE user currently logged in

Returns
string Html code snippet displaying the currently logged in user

Definition at line 314 of file BackendController.php.

References TYPO3\CMS\Backend\Controller\BackendController\$css, $GLOBALS, TYPO3\CMS\Backend\Utility\IconUtility\getSpriteIcon(), and TYPO3\CMS\Core\Utility\ExtensionManagementUtility\isLoaded().

Referenced by TYPO3\CMS\Backend\Controller\BackendController\renderToolbar().

◆ getPageRenderer()

TYPO3\CMS\Backend\Controller\BackendController::getPageRenderer ( )

◆ handlePageEditing()

◆ initializeCoreToolbarItems()

TYPO3\CMS\Backend\Controller\BackendController::initializeCoreToolbarItems ( )
protected

Initializes the core toolbar items

Returns
void

Definition at line 138 of file BackendController.php.

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

Referenced by TYPO3\CMS\Backend\Controller\BackendController\__construct().

◆ loadResourcesForRegisteredNavigationComponents()

◆ render()

◆ renderToolbar()

TYPO3\CMS\Backend\Controller\BackendController::renderToolbar ( )
protected

Renders the items in the top toolbar

Returns
string top toolbar elements as HTML

Definition at line 276 of file BackendController.php.

References TYPO3\CMS\Backend\Controller\BackendController\getLoggedInUserLabel().

Referenced by TYPO3\CMS\Backend\Controller\BackendController\render().

◆ setStartupModule()

TYPO3\CMS\Backend\Controller\BackendController::setStartupModule ( )
protected

Sets the startup module from either GETvars module and modParams or user configuration.

Returns
string the JavaScript code for the startup module

Definition at line 585 of file BackendController.php.

References $GLOBALS, and TYPO3\CMS\Core\Utility\GeneralUtility\_GET().

Referenced by TYPO3\CMS\Backend\Controller\BackendController\generateJavascript().

Member Data Documentation

◆ $content

TYPO3\CMS\Backend\Controller\BackendController::$content
protected

◆ $css

TYPO3\CMS\Backend\Controller\BackendController::$css
protected

◆ $cssFiles

TYPO3\CMS\Backend\Controller\BackendController::$cssFiles
protected

◆ $debug

TYPO3\CMS\Backend\Controller\BackendController::$debug
protected

Definition at line 47 of file BackendController.php.

◆ $js

TYPO3\CMS\Backend\Controller\BackendController::$js
protected

Definition at line 34 of file BackendController.php.

◆ $jsFiles

TYPO3\CMS\Backend\Controller\BackendController::$jsFiles
protected

◆ $jsFilesAfterInline

TYPO3\CMS\Backend\Controller\BackendController::$jsFilesAfterInline
protected

Definition at line 38 of file BackendController.php.

◆ $menuWidth

TYPO3\CMS\Backend\Controller\BackendController::$menuWidth
protected

Definition at line 45 of file BackendController.php.

◆ $menuWidthDefault

TYPO3\CMS\Backend\Controller\BackendController::$menuWidthDefault = 190
private

◆ $moduleLoader

TYPO3\CMS\Backend\Controller\BackendController::$moduleLoader
protected

Definition at line 54 of file BackendController.php.

◆ $moduleMenu

TYPO3\CMS\Backend\Controller\BackendController::$moduleMenu
protected

Definition at line 61 of file BackendController.php.

◆ $pageRenderer

TYPO3\CMS\Backend\Controller\BackendController::$pageRenderer
protected

◆ $toolbarItems

TYPO3\CMS\Backend\Controller\BackendController::$toolbarItems
protected

Definition at line 40 of file BackendController.php.