Changeset 887 for trunk/block/index.php


Ignore:
Timestamp:
Nov 20, 2020, 12:08:12 AM (3 years ago)
Author:
chronos
Message:
  • Added: Static types added to almost all classes, methods and function. Supported by PHP 7.4.
  • Fixed: Various found code issues.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/block/index.php

    r886 r887  
    11<?php
    22
    3 include_once('../Application/System.php');
     3include_once('../Application/Core.php');
    44
    55class BlockPage extends Page
    66{
    7   var $FullTitle = 'Blokování internetu';
    8   var $ShortTitle = 'Blokování internetu';
    9   var $Reasons = array(
     7  private array $Reasons = array(
    108    0 => 'Internet máte povolen, avšak došlo k chybě při kontrole přístupů k Internetu.',
    119    1 => 'Váš počítač má blokován přístup k internetu. Pravděpodobně je váš účet v mínusu. Přihlaste se do systému a zkontrolujte stav vašich plateb. ',
     
    1513  );
    1614
    17   function Show()
     15  function __construct(System $System)
     16  {
     17    parent::__construct($System);
     18    $this->FullTitle = 'Blokování internetu';
     19    $this->ShortTitle = 'Blokování internetu';
     20  }
     21
     22  function Show(): string
    1823  {
    1924    $Output = '<br/><div style="font-size: 20 pt;">Máte blokován přístup k Internetu.</div>
     
    4247}
    4348
    44 $System = new System();
     49$System = new Core();
    4550$System->ShowPage = false;
    4651$System->Run();
    47 $System->AddModule(new BlockPage($System));
    48 $System->Modules['BlockPage']->GetOutput();
     52$Page = new BlockPage($System);
     53echo($Page->GetOutput());
    4954
Note: See TracChangeset for help on using the changeset viewer.