-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
64 lines (56 loc) · 1.26 KB
/
index.php
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
<?php
include_once(dirname(__FILE__).'/bootstrap.php');
$model = strtolower($_REQUEST['model']);
$action = strtolower($_REQUEST['action']);
$sessionUser = $_SESSION['site']['ai_user'];
if(($model == '' || $model == 'login') && $sessionUser != '')
{
include_once(VIEWS ."/header/header.php");
include_once(VIEWS. '/dashboard/dashboard.php');
include_once(VIEWS ."/footer/footer.php");
}
else
{
if($model != '')
{
#echo "2";
if(file_exists(VIEWS. "/".$model."/".$model.'.php'))
{
#echo "3";
include_once(VIEWS ."/header/header.php");
if($action != '')
{
#echo "4";
if(include_once(VIEWS. "/".$model."/".$action.'.php'))
{
#echo "5";
include_once(VIEWS. "/".$model."/".$action.'.php');
}
else
{
#echo "6";
include_once(VIEWS. "/".$model."/".$model.'.php');
}
}
else
{
#echo "7";
include_once(VIEWS. "/".$model."/".$model.'.php');
}
include_once(VIEWS ."/footer/footer.php");
}
else
{
#echo "8";
include_once(VIEWS. "/error/error.php");
}
}
else
{
#echo "10";
include_once(VIEWS ."/header/header.php");
include_once(VIEWS. '/home/home.php');
include_once(VIEWS ."/footer/footer.php");
}
}
?>