Commit ab11514a authored by Eric Chavaillaz's avatar Eric Chavaillaz Committed by Christian Kuhn
Browse files

[FEATURE] Add hook to custom header in page mod

Add an hook to allow modifying the header of a page in the page module.
This hook is called before the content of the page is rendered.

Resolves: #52579
Releases: 6.2
Change-Id: I8914f5617d1529e98b9bc2b27cdc5a4378b0a7da
Reviewed-by: Daniel Huf
Reviewed-by: Xavier Perseguers
Tested-by: Xavier Perseguers
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
parent 9ed4d0f4
......@@ -953,6 +953,16 @@ class PageLayoutController {
// END: traverse tables
// For Context Sensitive Menus:
// Init the content
$content = '';
// Additional header content
$headerContentHook = $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/db_layout.php']['drawHeaderHook'];
if (is_array($headerContentHook)) {
foreach ($headerContentHook as $hook) {
$params = array();
$content .= GeneralUtility::callUserFunction($hook, $params, $this);
// Add the content for each table we have rendered (traversing $tableOutput variable)
foreach ($tableOutput as $table => $output) {
$content .= $this->doc->section('', $output, TRUE, TRUE, 0, TRUE);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment