forked from panique/mini3
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
37 lines (30 loc) · 1.11 KB
/
index.php
File metadata and controls
37 lines (30 loc) · 1.11 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
<?php
/**
* MINI - an extremely simple naked PHP application
*
* @package mini
* @author Panique
* @link http://www.php-mini.com
* @link https://github.com/panique/mini/
* @license http://opensource.org/licenses/MIT MIT License
*/
/**
* Now MINI work with namespaces + composer's autoloader (PSR-4)
*
* @author Joao Vitor Dias <[email protected]>
*
* For more info about namespaces plase @see http://php.net/manual/en/language.namespaces.importing.php
*/
// set a constant that holds the project's folder path, like "/var/www/".
// DIRECTORY_SEPARATOR adds a slash to the end of the path
define('ROOT', dirname(__DIR__) . DIRECTORY_SEPARATOR);
// set a constant that holds the project's "application" folder, like "/var/www/application".
define('APP', ROOT . 'application' . DIRECTORY_SEPARATOR);
// This is the auto-loader for Composer-dependencies (to load tools into your project).
require ROOT . 'vendor/autoload.php';
// load application config (error reporting etc.)
require APP . 'config/config.php';
// load application class
use Mini\Core\Application;
// start the application
$app = new Application();