Changeset 32 for page.php


Ignore:
Timestamp:
Mar 12, 2009, 12:42:00 PM (16 years ago)
Author:
george
Message:
  • Přidáno: Zobrazování ladících informací v patičce dle nastavení v config.php.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • page.php

    r19 r32  
    11<?php
     2
     3$ScriptStartTime = GetMicrotime();
    24
    35class Page extends Module
     
    5355    $Output = '<?xml version="1.0" encoding="'.$this->System->Config['Web']['Charset'].'"?>'."\n".
    5456    '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'.
    55     '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">'.
     57    '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="cs" lang="cs">'.
     58        '<meta http-equiv="content-type" content="application/xhtml+xml; charset='.$this->System->Config['Web']['Charset'].'" />'.
    5659    '<head><link rel="stylesheet" href="'.$this->System->Config['Web']['RootFolder'].'/style.css" type="text/css" media="all" />'.
    5760    '<script type="text/javascript" src="'.$this->System->Config['Web']['RootFolder'].'/global.js"></script>'.
     
    6366  function ShowFooter()
    6467  {
    65     $Time = floor((GetMicrotime() - $this->TimeStart) * 100) / 100;
    66     $Output = '<div id="Footer">
    67    <i>| Správa webu: '.$this->System->Config['Web']['Admin'].' | e-mail: '.$this->System->Config['Web']['AdminEmail'].' | Vygenerováno za '.$Time.' s | Použitá paměť:  '.HumanSize(memory_get_peak_usage(FALSE)).' |</i></div></body></html>';
     68        global $ScriptStartTime;
     69       
     70    $ScriptGenerateDuration = round(GetMicrotime() - $ScriptStartTime, 2);
     71    $Output = '<div class="Footer">| Správa webu: '.$this->System->Config['Web']['Admin'].' | E-mail: '.$this->System->Config['Web']['AdminEmail'].' |';
     72    if($this->System->Config['Web']['ShowRuntimeInfo'] == true) $Output .= ' Doba generování: '.$ScriptGenerateDuration.' s / '.ini_get('max_execution_time').' s | Použitá paměť: '.HumanSize(memory_get_peak_usage(FALSE)).' / '.ini_get('memory_limit').'B |';
     73    $Output .= '</div></body></html>';
    6874    return($Output);
    6975  }
Note: See TracChangeset for help on using the changeset viewer.