firts commit
This commit is contained in:
24
config/init.php
Normal file
24
config/init.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
$env="";
|
||||
|
||||
switch($env){
|
||||
/*------ DON'T TOUCH THIS PART ------ */
|
||||
case "generic":
|
||||
define('WEB_ROOT', $_SERVER['DOCUMENT_ROOT']);
|
||||
define('DOMAIN', $_SERVER['HTTP_HOST']);
|
||||
$protocol = (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off') ? 'https://' : 'http://';
|
||||
define('FULL_DOMAIN', $protocol . $_SERVER['HTTP_HOST']);
|
||||
define("ROOT_URL", "http://" . DOMAIN );
|
||||
define("ROOT_DIR", WEB_ROOT . "/");
|
||||
break;
|
||||
/* ----------------------------------- */
|
||||
default:
|
||||
include("config/functions_init.php");
|
||||
include("pages/env-error.php");
|
||||
die;
|
||||
|
||||
}
|
||||
require_once(ROOT_DIR . "config/constants.php");
|
||||
require_once(CONFIG_FOLD . "settings.php");
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user