2015-05-14 16:37:12 +02:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* This file includes all needed functions, connects to the db etc.
|
|
|
|
*/
|
|
|
|
require_once realpath(__DIR__ . '/../includes/mysqli_provider.php');
|
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../includes/sys_auth.php');
|
2016-11-14 18:14:23 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/sys_form.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/sys_log.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/sys_menu.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/sys_page.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/sys_template.php');
|
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/AngelType_model.php');
|
2016-09-27 17:49:13 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/EventConfig_model.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/LogEntries_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/Message_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/NeededAngelTypes_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/Room_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/ShiftEntry_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/Shifts_model.php');
|
2016-10-02 23:00:01 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/ShiftsFilter.php');
|
2016-11-12 23:00:46 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/ShiftSignupState.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/ShiftTypes_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/UserAngelTypes_model.php');
|
2015-12-19 23:31:08 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/UserDriverLicenses_model.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/UserGroups_model.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/model/User_model.php');
|
2016-11-18 08:20:17 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/model/ValidationResult.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../includes/view/AngelTypes_view.php');
|
2016-09-27 17:49:13 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/EventConfig_view.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/Questions_view.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/view/Rooms_view.php');
|
2016-11-05 10:06:06 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/ShiftCalendarLane.php');
|
2016-10-02 21:19:03 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/ShiftCalendarRenderer.php');
|
2016-11-07 20:50:15 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/ShiftCalendarShiftRenderer.php');
|
2016-10-05 18:56:50 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/ShiftsFilterRenderer.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/Shifts_view.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/view/ShiftEntry_view.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/view/ShiftTypes_view.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/view/UserAngelTypes_view.php');
|
2015-12-19 23:31:08 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/UserDriverLicenses_view.php');
|
2016-11-15 16:28:20 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/UserHintsRenderer.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/view/User_view.php');
|
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/angeltypes_controller.php');
|
2016-09-27 17:49:13 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/event_config_controller.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/rooms_controller.php');
|
2016-10-02 21:19:03 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/shift_entries_controller.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/shifts_controller.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/shifttypes_controller.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/users_controller.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/user_angeltypes_controller.php');
|
2015-12-19 23:31:08 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/controller/user_driver_licenses_controller.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
|
2015-08-16 23:08:02 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/helper/graph_helper.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/helper/internationalization_helper.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/helper/message_helper.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/helper/error_helper.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/helper/email_helper.php');
|
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../includes/mailer/shifts_mailer.php');
|
2015-12-30 15:48:41 +01:00
|
|
|
require_once realpath(__DIR__ . '/../includes/mailer/users_mailer.php');
|
2015-05-14 16:37:12 +02:00
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../config/config.default.php');
|
2016-09-29 11:28:42 +02:00
|
|
|
if (file_exists(realpath(__DIR__ . '/../config/config.php'))) {
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../config/config.php');
|
2016-09-29 11:28:42 +02:00
|
|
|
}
|
2015-05-14 16:37:12 +02:00
|
|
|
|
2017-01-01 15:43:20 +01:00
|
|
|
defined('CRYPT_ALG') || define('CRYPT_ALG', '$6$rounds=5000'); // SHA-512
|
|
|
|
defined('MIN_PASSWORD_LENGTH') || define('MIN_PASSWORD_LENGTH', 8);
|
|
|
|
|
2015-08-09 17:46:57 +02:00
|
|
|
if ($maintenance_mode) {
|
|
|
|
echo file_get_contents(__DIR__ . '/../public/maintenance.html');
|
|
|
|
die();
|
|
|
|
}
|
|
|
|
|
2015-05-14 16:37:12 +02:00
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_active.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_arrive.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_free.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_groups.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_import.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_log.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_questions.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_rooms.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_shifts.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/admin_user.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/guest_login.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/user_messages.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/user_myshifts.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/user_news.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/user_questions.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/user_settings.php');
|
|
|
|
require_once realpath(__DIR__ . '/../includes/pages/user_shifts.php');
|
|
|
|
|
|
|
|
require_once realpath(__DIR__ . '/../vendor/parsedown/Parsedown.php');
|
|
|
|
|
2015-06-07 13:33:59 +02:00
|
|
|
session_start();
|
|
|
|
|
2015-05-14 16:37:12 +02:00
|
|
|
gettext_init();
|
|
|
|
|
|
|
|
sql_connect($config['host'], $config['user'], $config['pw'], $config['db']);
|
|
|
|
|
|
|
|
load_auth();
|
|
|
|
|
2015-08-26 13:33:38 +02:00
|
|
|
?>
|