mirror of
https://github.com/phpbb/phpbb.git
synced 2025-02-24 12:03:21 +01:00
[feature/events] Add core.page_header_override
Add a ledge that will allow listeners to override the build in `page_header` function. http://area51.phpbb.com/phpBB/viewtopic.php?f=111&t=42741&p=237037 PHPBB3-9550
This commit is contained in:
parent
a247bfc2b6
commit
6b1ca27a86
@ -4753,6 +4753,16 @@ function page_header($page_title = '', $display_online_list = true, $item_id = 0
|
||||
|
||||
define('HEADER_INC', true);
|
||||
|
||||
// A listener can set this variable to `true` when it overrides this function
|
||||
$page_header_override = false;
|
||||
|
||||
$vars = array('page_title', 'display_online_list', 'item_id', 'item', 'page_header_override');
|
||||
extract($phpbb_dispatcher->trigger_event('core.page_header_override', compact($vars)));
|
||||
if ($page_header_override)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// gzip_compression
|
||||
if ($config['gzip_compress'])
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user