first commit
This commit is contained in:
59
socket/common.php
Normal file
59
socket/common.php
Normal file
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
|
||||
defined('VALID_INCLUDE') or exit('Restricted area');
|
||||
|
||||
header('Cache-Control: no-cache');
|
||||
header('Pragma: no-cache');
|
||||
header('Expires: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
ini_set('memory_limit', '2G');
|
||||
ini_set('max_execution_time', '600');
|
||||
|
||||
// //////////////////// SOUBOR COMMON.PHP
|
||||
|
||||
// zacit pocitat cas provadeni skriptu
|
||||
setStartTime();
|
||||
|
||||
// ################################################################
|
||||
// SESSION
|
||||
// ################################################################
|
||||
|
||||
// session_start();
|
||||
|
||||
// ################################################################
|
||||
// ERROR REPORTING
|
||||
// ################################################################
|
||||
|
||||
set_error_handler('error_handler');
|
||||
|
||||
getRaven();
|
||||
|
||||
// ################################################################
|
||||
// VOLBA JAZYKA
|
||||
// ################################################################
|
||||
|
||||
$lng = (isset($cfg['Lang']['language'])) ? $cfg['Lang']['language'] : 'czech';
|
||||
// sestaveni jmena souboru
|
||||
$script = 'lang/lang.'.$lng.'.php';
|
||||
|
||||
if (file_exists($script)) {
|
||||
require_once $script;
|
||||
} else {
|
||||
$script = $cfg['Path']['admin_to_root'].$cfg['Path']['shared_version'].'socket/lang/lang.'.$lng.'.php';
|
||||
if (file_exists($script)) {
|
||||
require_once $script;
|
||||
} else {
|
||||
$script = $cfg['Path']['admin_to_root'].$cfg['Path']['shared_version'].'socket/lang/lang.czech.php';
|
||||
require_once $script;
|
||||
}
|
||||
}
|
||||
|
||||
// ################################################################
|
||||
// ZISKANI NASTAVENI Z DATABAZE
|
||||
// ################################################################
|
||||
|
||||
$dbcfg = Settings::getDefault();
|
||||
|
||||
// ################################################################
|
||||
//
|
||||
// ################################################################
|
||||
Reference in New Issue
Block a user