private static function confgFiles(array $config, array $db) { Confgs::putFile(BASE_PATH . '/etc/confg.ll', $config); Confgs::putFile(BASE_PATH . '/etc/db.confg.ll', $db); }
$_ll['url']['home'] = (isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ? 'https' : 'http') . '://' . $_SERVER['HTTP_HOST'] . $bptw . '/'; $_ll['url']['path'] = $bsgt; $_ll['url']['base'] = $_ll['url']['home'] . $_ll['url']['path']; $_ll['url']['full'] = $_ll['url']['base'] . $qyst; $_ll['url']['get'] = !empty($bsgt) ? explode('/', $bsgt) : array(); unset($file, $bptw, $qyst, $rdtu, $bsgt); /** Carregando e configunado o Autoload */ require_once BASE_PATH . DS . 'usr' . DS . 'AutoLoad.php'; AutoLoad::setPath(BASE_PATH . DS . 'usr'); AutoLoad::setPath(BASE_PATH . DS . 'api'); AutoLoad::setPath(BASE_PATH . DS . 'app'); /** Verifica a existemcia do inicialozador (confg.php) */ if (!file_exists($f = BASE_PATH . DS . 'etc' . DS . 'confg.ll')) { die('file: ' . $f . '; não existemte.'); } else { $_ll = array_merge($_ll, Confgs::getFile($f)); } /** starta todas os difines configurados */ foreach ($_ll['defines'] as $name => $value) { if (!defined($name)) { define($name, $value); } } /** retorna os dados processados/carregados pelo start */ if (str_replace('/', DS, trim($_SERVER['DOCUMENT_ROOT'], DS) . $_SERVER['SCRIPT_NAME']) !== trim(str_replace('/', DS, __FILE__), DS)) { return $_ll; } $_ll['operation_types'] = array('opt', 'api', 'app'); $_ll['operation_mode'] = 'start'; $_ll['operation_type'] = false; $_ll['enter_mode'] = 'start';