1. sfWebDebugPanelMemory.class.php
  2. /** * sfWebDebugPanelMemory adds a panel to the web debug toolbar with the memory used by the script. * * @package symfony * @subpackage debug * @author Fabien Potencier * @version SVN: $Id: sfWebDebugPanelMemory.class.php 21069 2009-08-11 23:28:20Z Kris.Wallsmith $ */
  3. class sfWebDebugPanelMemory extends sfWebDebugPanel
  4. {
  5. public function getTitle()
  6. {
  7. $totalMemory = sprintf('%.1f', (memory_get_peak_usage(true) / 1024));
  8. return '<img src="'.$this->webDebug->getOption('image_root_path').'/memory.png" alt="Memory" /> '.$totalMemory.' KB';
  9. }
  10. public function getPanelTitle()
  11. {
  12. }
  13. public function getPanelContent()
  14. {
  15. }
  16. }

Debug toolbar