Changeset 32


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

Legend:

Unmodified
Added
Removed
  • config.sample.php

    r27 r32  
    1414  'Web' => array
    1515  (
    16     'Charset' => 'UTF-8',
     16    'Charset' => 'utf-8',
    1717    'Host' => 'localhost',
    1818    'RootFolder' => 'http://localhost/webis',
     
    2222    'AdminEmail' => 'admin@localhost',
    2323    'ItemsPerPage' => 20,
     24        'ShowSQLError' => true,
     25        'ShowPHPError' => true,
     26        'ShowRuntimeInfo' => true,
    2427  ),
    2528  'User' => array
  • index.php

    r22 r32  
    1313    $FormUserLogin = array(
    1414      'Title' => 'Přihlášení',
    15       'SubmitBuffonText' => 'Přihlásit',
     15      'SubmitButtonText' => 'Přihlásit',
    1616      'Items' => array(
    1717        array('Name' => 'UserName', 'Type' => TypeStringId, 'Caption' => 'Jméno', 'Value' => ''),
     
    2323      'Title' => 'Registrace uživatele',
    2424      'Table' => 'User',
    25       'SubmitBuffonText' => 'Registrovat',
     25      'SubmitButtonText' => 'Registrovat',
    2626      'Items' => array(
    2727        array('Name' => 'UserName', 'Type' => TypeStringId, 'Caption' => 'Přihlašovací jméno', 'Value' => ''),
  • 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  }
  • style.css

    r19 r32  
    133133}
    134134
    135 #Footer
     135.Footer
    136136{
    137137  border-style: solid;
  • types/Base.php

    r29 r32  
    33class TypeBase
    44{
     5  var $DatabaseCompareOperators = array();
     6
    57  function OnView($Item)
    68  {
Note: See TracChangeset for help on using the changeset viewer.