Ignore:
Timestamp:
Feb 16, 2013, 4:23:29 PM (11 years ago)
Author:
chronos
Message:
  • Upraveno: Konfigurační soubor se bude dále generovat ze skriptu z vyplněného formuláře s nastavením přímo do souboru namísto kopírováním šablony config.sample.php.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/global.php

    r510 r511  
    88include_once(dirname(__FILE__).'/Page.php');
    99include_once(dirname(__FILE__).'/error.php');
     10if(file_exists(dirname(__FILE__).'/config.php'))
     11  include_once(dirname(__FILE__).'/config.php');
     12include_once(dirname(__FILE__).'/Version.php');
    1013
    1114GlobalInit();
     
    1316function GlobalInit()
    1417{
    15         global $System, $ScriptStartTime, $TranslationTree, $User, $StopAfterUpdateManager,
    16           $UpdateManager, $Config;
     18  global $System, $ScriptStartTime, $TranslationTree, $User, $StopAfterUpdateManager,
     19        $UpdateManager, $Config;
    1720
    1821  $ScriptStartTime = GetMicrotime();
     
    2023  if(isset($_SERVER['REMOTE_ADDR'])) session_start();
    2124
    22   if(file_exists(dirname(__FILE__).'/config.php')) include_once(dirname(__FILE__).'/config.php');
    23     else die('Nenalezen konfigurační soubor config.php ve složce includes. '.
    24           'Vytvořte jej zkopírováním vzoru config.sample.php.');
     25  if(!isset($Config)) die('Systém není nainstalován. Pokračujte v instalaci <a href="admin/install.php">zde</a>.');
    2526  date_default_timezone_set($Config['Web']['Timezone']);
    26  
    27   $Revision = 510; // Subversion revision
    28   $ReleaseTime = '2013-02-15'; 
    2927 
    3028  $System = new System();
     
    3533  $UpdateManager->Database = $System->Database;
    3634  $UpdateManager->Revision = $Revision;
    37   if(isset($StopAfterUpdateManager)) return;
    3835  if(!$UpdateManager->IsInstalled()) die('Systém vyžaduje instalaci databáze.');
    3936  if(!$UpdateManager->IsUpToDate()) die('Systém vyžaduje aktualizaci databáze.');
Note: See TracChangeset for help on using the changeset viewer.