venom/public/index.php

26 lines
578 B
PHP
Raw Normal View History

2020-03-02 10:59:28 +01:00
<?php
2020-03-28 20:11:51 +01:00
use Venom\Core\Config;
use Venom\Core\Setup;
2020-09-25 21:33:54 +02:00
use Venom\Helper\URLHelper;
2020-03-28 20:11:51 +01:00
use Venom\Venom;
2020-03-02 10:59:28 +01:00
require_once '../vendor/autoload.php';
2020-09-25 21:33:54 +02:00
session_start();
Setup::loadConfig(URLHelper::getInstance()->isAdminUrl());
Setup::loadLanguage();
2020-03-28 20:11:51 +01:00
$config = Config::getInstance();
if ($config->isMaintenance()) {
echo 'Currently not available';
exit;
}
//if devMode is on show all errors!
if ($config->isDevMode()) {
error_reporting(E_ALL);
ini_set('error_reporting', E_ALL);
}
2020-03-28 20:11:51 +01:00
$venom = new Venom();
Setup::loadRouters($venom);
Setup::loadModules($venom);
2020-09-25 21:33:54 +02:00
$venom->inject();