public static function run($configFile, $applicationEnv) { Loader::registerAutoload(); self::$request = new Request(); self::$response = new Response(); include $configFile; self::$config = $config[$applicationEnv]; StringHelper::setCryptKey(self::$config['crypt_key']); self::$db = new Db(self::$config['db']['params']); self::initView(); self::startDispatch(); }