8122384dcbe6bfa5db56c62a789c2f3056fdb534
[noxon-gateway.git] / src / header.php
1 <?php
2 set_include_path(get_include_path() . PATH_SEPARATOR . __DIR__ . '/../src/');
3 $fullUri = $_SERVER['REQUEST_URI'];
4 if (isset($_SERVER['REDIRECT_URL'])) {
5     $path    = $_SERVER['REDIRECT_URL'];
6 } else {
7     $path = '/';
8 }
9 $dataDir = __DIR__ . '/../data/';
10 $varDir  = realpath(__DIR__ . '/../var') . '/';
11 $cacheDir = __DIR__ . '/../www/cache/';
12 $host1 = 'http://radio567.vtuner.com/';
13 $host2 = 'http://radio5672.vtuner.com/';
14 if ($_SERVER['HTTP_HOST'] !== '') {
15     $host1 = 'http://' . $_SERVER['HTTP_HOST'] . '/';
16     $host2 = 'http://' . $_SERVER['HTTP_HOST'] . '/';
17 }
18 $cacheDirUrl = $host1 . 'cache/';
19 $cfgFile = $dataDir . 'config.php';
20 if (file_exists($cfgFile)) {
21     include $cfgFile;
22 }
23 ?>