Changeset 738 for trunk/Common/Page.php


Ignore:
Timestamp:
Apr 14, 2015, 10:20:16 PM (9 years ago)
Author:
chronos
Message:
  • Removed: Spaces on end of line.
  • Modified: Tabs converted to spaces.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Common/Page.php

    r729 r738  
    1515  var $Encoding;
    1616  var $Style;
    17  
     17
    1818  function __construct($System)
    1919  {
    2020    parent::__construct($System);
    21    
     21
    2222    $this->FormatHTML = false;
    2323    $this->ShowRuntimeInfo = false;
    2424    $this->Encoding = 'utf-8';
    2525    $this->Style = 'new';
    26    
     26
    2727    // TODO: Move to external code
    2828    if(isset($this->System->Config['Web']['FormatHTML']))
     
    3535      $this->Style = $this->System->Config['Web']['Style'];
    3636  }
    37  
     37
    3838  function Show()
    3939  {
    40         return('');
     40    return('');
    4141  }
    4242
    4343  function SystemMessage($Title, $Text)
    44   { 
     44  {
    4545    return('<table align="center"><tr><td><div class="SystemMessage"><h3>'.$Title.'</h3><div>'.$Text.'</div></div></td></tr></table>');
    4646    //ShowFooter();
     
    5050  function ShowHeader($Title, $Path)
    5151  {
    52         if(array_key_exists('REQUEST_URI', $_SERVER))
     52    if(array_key_exists('REQUEST_URI', $_SERVER))
    5353      $ScriptName = $_SERVER['REQUEST_URI'];
    54           else $ScriptName = '';
     54      else $ScriptName = '';
    5555    while(strpos($ScriptName, '//') !== false)
    5656      $ScriptName = str_replace('//', '/', $ScriptName);
     
    6262    $Navigation = '';
    6363    while($Page)
    64     { 
     64    {
    6565      $Navigation = ' &gt; <a href="'.$this->System->Link($ScriptName).'/">'.$Page->ShortTitle.'</a>'.$Navigation;
    66      
     66
    6767      if(class_exists($Page->ParentClass))
    6868      {
     
    7171        $ScriptName = substr($ScriptName, 0, strrpos($ScriptName, '/'));
    7272      } else $Page = null;
    73     } 
     73    }
    7474    $Navigation = substr($Navigation, 6);
    7575
     
    8989      //$Output .= '<div class="MainTitle">'.$Title.'</div>';
    9090      $Output .= '<div class="MainTitle"><span class="MenuItem"><strong>Navigace :: </strong> '.$Navigation.'</span><div class="MenuItem2">';
    91         foreach($this->System->Bars['Top'] as $BarItem)
    92         $Output .= call_user_func($BarItem);
     91      foreach($this->System->Bars['Top'] as $BarItem)
     92        $Output .= call_user_func($BarItem);
    9393      $Output .= '</div></div>';
    9494    }
     
    9999  {
    100100    global $ScriptTimeStart, $Revision, $ReleaseTime;
    101    
     101
    102102    $Time = round(GetMicrotime() - $ScriptTimeStart, 2);
    103103    $Output = '';
     
    112112    }
    113113    $Output .= '</body></html>';
    114     return($Output); 
     114    return($Output);
    115115  }
    116116
     
    122122    //  $Output = 'Chyba: '.$E->getMessage();
    123123    //}
    124     if($this->ClearPage == false) 
     124    if($this->ClearPage == false)
    125125    {
    126126      $Output = $this->ShowHeader($this->FullTitle, $this->ShortTitle).$Output;
     
    130130    echo($Output);
    131131  }
    132  
     132
    133133  function NewPage($ClassName)
    134134  {
     
    156156      }
    157157      $line = trim(substr($s, $start, $end + 1));
    158       if(strlen($line) > 0) 
     158      if(strlen($line) > 0)
    159159      if($line[0] == '<')
    160160      {
    161         if($s[$start + 1] == '/') 
     161        if($s[$start + 1] == '/')
    162162        {
    163163          $n = $n - 2;
    164164          $nn = $n;
    165         } else 
     165        } else
    166166        {
    167167          if(strpos($line, ' ')) $cmd = substr($line, 1, strpos($line, ' ') - 1);
     
    169169          //echo('['.$cmd.']');
    170170          if(strpos($s, '</'.$cmd.'>')) $n = $n + 2;
    171         }   
     171        }
    172172      }// else $line = '['.$line.']';
    173173      //if($line != '') echo(htmlspecialchars(str_repeat(' ',$nn).$line."\n"));
Note: See TracChangeset for help on using the changeset viewer.