-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
65 lines (44 loc) · 1.18 KB
/
Copy pathindex.php
File metadata and controls
65 lines (44 loc) · 1.18 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
define('PUMP', 'Og3');
mb_internal_encoding("UTF-8");
//error_reporting( E_ERROR );
try {
require ('core/exception.php');
require ('core/config.php');
require ('core/router.php');
require ('core/abstract_coreDB.php');
require ('core/temp_generator.php');
require ('core/assistant.php');
require ('core/layout_helper.php');
/*******test set******/
session_start();
if(!$_SESSION['TESTER'] && empty($_POST)){
require ('TESTER.tpl');
exit;
}
/*******test set******/
$Router = new Router($_SERVER['REQUEST_URI']);
$Router->parseUrl();
$controller = $Router->getController();
$params = $Router->getParams();
//session_start(); //statistic;
if(empty($_POST)){
require ('app/controller/'.$controller.'_controller.php');
$controller = (ucfirst($controller).'Controller');
$Page = new $controller($params);
$Page->work();
}else{
//SEARCH REQUEST
//!!!HTTP_REFERER БЕЗОПАСТНОСТЬ!!
require ('core/validator.php');
$DataBase = DB::getDBO();
$Assistant = Assistant::getAssistant();
$Validator = new Validator();
require ('ajax/common/common_ajax.php');
}
}catch (MyExp $ex){
$ex->work();
exit();
}
exit();
?>