mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/12687] Add a constant to display the load time without DEBUG
PHPBB3-12687
This commit is contained in:
parent
456ff2559a
commit
39b76a628b
2 changed files with 6 additions and 6 deletions
|
@ -5062,7 +5062,7 @@ function page_footer($run_cron = true, $display_template = true, $exit_handler =
|
|||
}
|
||||
|
||||
// Output page creation time
|
||||
if (defined('DEBUG'))
|
||||
if (defined('DISPLAY_LOAD_TIME'))
|
||||
{
|
||||
$mtime = explode(' ', microtime());
|
||||
$totaltime = $mtime[0] + $mtime[1] - $starttime;
|
||||
|
@ -5074,7 +5074,7 @@ function page_footer($run_cron = true, $display_template = true, $exit_handler =
|
|||
|
||||
$debug_output = sprintf('Time : %.3fs | ' . $db->sql_num_queries() . ' Queries | GZIP : ' . (($config['gzip_compress'] && @extension_loaded('zlib')) ? 'On' : 'Off') . (($user->load) ? ' | Load : ' . $user->load : ''), $totaltime);
|
||||
|
||||
if ($auth->acl_get('a_') && defined('DEBUG'))
|
||||
if ($auth->acl_get('a_') && defined('DISPLAY_LOAD_TIME'))
|
||||
{
|
||||
if (function_exists('memory_get_peak_usage'))
|
||||
{
|
||||
|
@ -5091,7 +5091,7 @@ function page_footer($run_cron = true, $display_template = true, $exit_handler =
|
|||
}
|
||||
|
||||
$template->assign_vars(array(
|
||||
'DEBUG_OUTPUT' => (defined('DEBUG')) ? $debug_output : '',
|
||||
'DEBUG_OUTPUT' => (defined('DISPLAY_LOAD_TIME')) ? $debug_output : '',
|
||||
'TRANSLATION_INFO' => (!empty($user->lang['TRANSLATION_INFO'])) ? $user->lang['TRANSLATION_INFO'] : '',
|
||||
'CREDIT_LINE' => $user->lang('POWERED_BY', '<a href="https://www.phpbb.com/">phpBB</a>® Forum Software © phpBB Limited'),
|
||||
|
||||
|
|
|
@ -147,7 +147,7 @@ function adm_page_footer($copyright_html = true)
|
|||
}
|
||||
|
||||
// Output page creation time
|
||||
if (defined('DEBUG'))
|
||||
if (defined('DISPLAY_LOAD_TIME'))
|
||||
{
|
||||
$mtime = explode(' ', microtime());
|
||||
$totaltime = $mtime[0] + $mtime[1] - $starttime;
|
||||
|
@ -159,7 +159,7 @@ function adm_page_footer($copyright_html = true)
|
|||
|
||||
$debug_output = sprintf('Time : %.3fs | ' . $db->sql_num_queries() . ' Queries | GZIP : ' . (($config['gzip_compress']) ? 'On' : 'Off') . (($user->load) ? ' | Load : ' . $user->load : ''), $totaltime);
|
||||
|
||||
if ($auth->acl_get('a_') && defined('DEBUG'))
|
||||
if ($auth->acl_get('a_') && defined('DISPLAY_LOAD_TIME'))
|
||||
{
|
||||
if (function_exists('memory_get_peak_usage'))
|
||||
{
|
||||
|
@ -176,7 +176,7 @@ function adm_page_footer($copyright_html = true)
|
|||
}
|
||||
|
||||
$template->assign_vars(array(
|
||||
'DEBUG_OUTPUT' => (defined('DEBUG')) ? $debug_output : '',
|
||||
'DEBUG_OUTPUT' => (defined('DISPLAY_LOAD_TIME')) ? $debug_output : '',
|
||||
'TRANSLATION_INFO' => (!empty($user->lang['TRANSLATION_INFO'])) ? $user->lang['TRANSLATION_INFO'] : '',
|
||||
'S_COPYRIGHT_HTML' => $copyright_html,
|
||||
'CREDIT_LINE' => $user->lang('POWERED_BY', '<a href="https://www.phpbb.com/">phpBB</a>® Forum Software © phpBB Limited'),
|
||||
|
|
Loading…
Add table
Reference in a new issue