-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
65 lines (62 loc) · 1.78 KB
/
Copy pathindex.php
File metadata and controls
65 lines (62 loc) · 1.78 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php
//+------------------------------------------------------------------+
//| Copyright c 2012, RedButton Web Sites Generator |
//| http://www.getredbutton.com |
//+------------------------------------------------------------------+
ini_set('display_errors', 1);
error_reporting(E_ALL);
header('Content-Type:text/html; charset=UTF-8');
//---
$VERSION_FULL = "build 3.92 22 November 2015";
$BUILD = "92";
//--- означает релизная версия
$IS_CRYPT = 1;
//---
include_once('inc/lib/controller.php');
include_once('inc/lib/logs.php');
include_once('inc/languages.php');
include_once('inc/lib/icontroller.php');
//---
include_once('inc/lib/ipage.php');
include_once('inc/config.php');
//--- получение языка
$LNG = CModel_lng::GetLanguage();
//---
include_once('inc/lib/iplugin.php');
//---
if(file_exists('data/plugins_config.php')) include_once('data/plugins_config.php');
//---
include_once('auth.php');
//---
//--- иницилизация лога
CLogger::Init("", true, './data/tmp/logs', '');
//--- название класса для базовой страницы
$PAGE_NAME = '';
session_start();
//---
if(isset($_REQUEST['module'])) $PAGE_NAME = $_REQUEST['module'];
//---
if($PAGE_NAME == '') $PAGE_NAME = 'home';
//---
$PAGE_CLASS_NAME = "C" . $PAGE_NAME;
if(!class_exists($PAGE_CLASS_NAME))
{
//--- класса не существует, до свидания
C404::Show404();
exit;
}
$CUR_PAGE = new $PAGE_CLASS_NAME();
//---
if(isset($_REQUEST['a']) && is_array($_REQUEST['a']))
{
$CUR_PAGE->action(null, key($_REQUEST['a']));
}
else
{
$template = $CUR_PAGE->GetTemplate();
//---
if($template != '') include('./inc/views/' . $template . '.phtml');
else
$CUR_PAGE->Show(null);
}
?>