I believe the generation data occurs after the footer... in the page_tail.
I experimented and achieved success with minimal changes.
OPEN: page_tail.php
FIND: (mine's starts on line 113)
- Code: Select all
if( defined('DEBUG') ){ $debug_out = '<div>[Page generation time]</div>';}else{ $debug_out = '<br>';}
Put // in front of the
if and // in front of the
else. On my site, this removed the page generation line with no issues that I could tell.
NOTE - On line 90 of page_tail.php, I found
- Code: Select all
/* Un-comment the line below to restrict Admins only to view page generation info */
This seems much better. That way admins could still see that information. However, I couldn't get it to work that simply. (Perhaps I'm stupid.) I had to uncomment several lines and move a closing } to after the code posted above. It seems to work fine. When I'm logged in as an admin, it shows the page generation information but it doesn't if I'm not logged in as an admin.
If you want to try it, back up your page_tail.php, and then here's my edited replacement code from after
- Code: Select all
/* Un-comment the line below to restrict Admins only to view page generation info */
to right before
- Code: Select all
$template->assign_vars(array(
REPLACEMENT CODE TO ONLY SHOW PAGE GEN TO ADMINS] if( ($userdata['session_logged_in']) and ($userdata['user_level'] == ADMIN) ){ $gzip_text = ($board_config['gzip_compress']) ? 'GZIP enabled' : 'GZIP disabled'; $debug_text = (DEBUG == 1) ? 'Debug on' : 'Debug off'; $excuted_queries = $db->num_queries; $mtime = microtime(); $mtime = explode(" ",$mtime); $mtime = $mtime[1] + $mtime[0]; $endtime = $mtime; $gentime = round(($endtime - $starttime), 4); $sql_time = round($db->sql_time, 4); $sql_part = round($sql_time / $gentime * 100); $php_part = 100 - $sql_part; if( defined('DEBUG') ){ $debug_out = '<div>[Page generation time: '. $gentime .'s (PHP: '. $php_part .'% | SQL: '. $sql_part .'%) | SQL queries: '. $excuted_queries .' | '. $gzip_text .' | '. $debug_text .']</div>';}else{ $debug_out = '<br>';}} [/code]
(Hope this makes sense. Now you see why I'm not good at coding stuff...)