Dragon-Knight/server/boot/Boot.php

32 lines
873 B
PHP
Raw Normal View History

<?php
/*
This script loads all the ugly stuff we need to get the app working.
The script that uses this boot script will need to supply a SERVER
constant to define where the server root folder is.
*/
define('START', microtime(true)); // start the timer for this execution
// @todo move these to a settings config somewhere
const VERSION = '1.1.11';
const BUILD = '';
const DB = SERVER.'/database/dragon.db';
// @todo use a flag for this
ini_set('display_errors', 'on');
error_reporting(E_ALL | E_STRICT);
require_once SERVER.'/boot/Autoloader.php'; // include our autoloader
require_once SERVER.'/boot/Library.php'; // include our miscellaneous functions
// define whether we are installed or not
define('INSTALLED', file_exists(SERVER.'/.installed'));
// register our autoloader
Autoloader::boot();
// boot the settings for authentication
Auth::boot();