-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
74 lines (58 loc) · 2.81 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
65
66
67
68
69
70
71
72
73
74
<?php
/***********************************************************************************/
/* (C) 2021 - Skyfallen */
/* Skyfallen Developer Center Developed by */
/* The Skyfallen Company */
/* */
/* This file is where all requests are redirected to. All file inclusions are here.*/
/***********************************************************************************/
error_reporting(E_ALL);
ini_set("display_errors",1);
ini_set("display_startup_errors",1);
// Define the application's ABSOLUTE FS Path
define("SDC_ABSPATH", dirname(__FILE__));
// Include All Configuration Files
include_once SDC_ABSPATH."/Configuration/UpdaterConfiguration.php";
include_once SDC_ABSPATH."/thisversion.php";
// Unless the installation was complete, the Database Config should exist, if not, present an error.
if((@include_once SDC_ABSPATH . "/Configuration/SkyfallenDeveloperCenterConfiguration.php") === false){
// Stop further execution
die("There is no configuration file found.");
}
// Create the htaccess if not exists
if(!file_exists(SDC_ABSPATH . "/.htaccess")){
// Include the install file
include_once SDC_ABSPATH."/csc.php";
// Stop further execution
die();
}
// Include PRE-SESSION Classes
include_once SDC_ABSPATH."/SDC_FunctionSets/DBSettings.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDC_Router.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDC_CSRF.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDCUser.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDCOrganisation.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDCEmail.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDCApp.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDCService.php";
include_once SDC_ABSPATH."/SDC_FunctionSets/SDC_LSLog.php";
// Include all SCL Libraries
include_once SDC_ABSPATH."/SkyfallenCodeLib/UpdatesConsoleConnector.php";
// Include Mailing Library
include_once SDC_ABSPATH."/Mailer/PHPMailer.php";
include_once SDC_ABSPATH."/Mailer/SMTP.php";
include_once SDC_ABSPATH."/Mailer/OAuth.php";
include_once SDC_ABSPATH."/Mailer/POP3.php";
include_once SDC_ABSPATH."/Mailer/Exception.php";
// Start Session
session_name("SDCSession");
session_start();
// Include POST-SESSION Helpers
include_once SDC_ABSPATH."/SDC_Includes/CSRF_Session_Helper.php";
include_once SDC_ABSPATH."/SDC_Includes/UserSessionHelper.php";
// Include Utility Functions
include_once SDC_ABSPATH."/SDC_Includes/utility_functions.php";
// Include the URL Handler to verify the URL and the request.
include_once SDC_ABSPATH."/URLHandler.php";
// Include the router file to route the URLs
include_once SDC_ABSPATH."/router.php";