11
sarahmx
Re: Execution Time in theme ?
  • 2010/6/12 12:28

  • sarahmx

  • Quite a regular

  • Posts: 381

  • Since: 2007/10/28


Thank you underdog

I received this same result for all page

Page generated 7 queries - Generation time: 0.0000 seconds

Quote:

and this code work only in case xoopslogger is activated.


How to activate this ?

12
trabis
Re: Execution Time in theme ?
  • 2010/6/12 13:50

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


Quote:

sarahmx wrote:
Thank you underdog

I received this same result for all page

Page generated 7 queries - Generation time: 0.0000 seconds

Quote:

and this code work only in case xoopslogger is activated.


How to activate this ?


You need to activate debug mode in system general preferences.
If you don't want to show the debug info then edit include/common.php line 125(xoops 2.4.5) and comment out the enableRendering method.

le="color: #000000"><?php /** * Start of Error Reportings. */ if ($xoopsConfig['debug_mode'] == 1 || $xoopsConfig['debug_mode'] == 2) { xoops_loadLanguage('logger'); error_reporting(E_ALL); //$xoopsLogger->enableRendering(); $xoopsLogger->usePopup = ($xoopsConfig['debug_mode'] == 2); } else { error_reporting(0); $xoopsLogger->activated = false; }

13
sarahmx
Re: Execution Time in theme ?
  • 2010/6/12 15:27

  • sarahmx

  • Quite a regular

  • Posts: 381

  • Since: 2007/10/28


yes that makes it works ..thanks trabis

this should be add to core..

so need no to edit common.php

14
jimmyx
Re: Execution Time in theme ?
  • 2011/5/1 12:18

  • jimmyx

  • Quite a regular

  • Posts: 338

  • Since: 2007/7/18


le="color: #000000"><?php <{php}> $XoopsTime = $GLOBALS['xoopsLogger']->dumpTime( 'XOOPS' ); $XoopsQueries = count( $GLOBALS['xoopsLogger']->queries); echo '<p align="center">Page generated <span style="color:#ff0000;">' . $XoopsQueries . '</span> queries - Generation time: <span style="color:#ff0000;">' . sprintf( "%.4f", $XoopsTime ) . '</span> seconds</p>' . "n"; <{/php}>


how to enable this without enabling debug message ?

15
jimmyx
Re: Execution Time in theme ?
  • 2011/5/1 12:40

  • jimmyx

  • Quite a regular

  • Posts: 338

  • Since: 2007/7/18