if (!defined('VANILLA_CONSTANTS')) { include PATH_CONF . '/constants.php'; } // Make sure a default time zone is set date_default_timezone_set('UTC'); // Make sure the mb_* functions are utf8. if (function_exists('mb_internal_encoding')) { mb_internal_encoding('UTF-8'); } // Include the core function definitions require_once PATH_LIBRARY_CORE . '/functions.error.php'; require_once PATH_LIBRARY_CORE . '/functions.general.php'; require_once PATH_LIBRARY_CORE . '/functions.compatibility.php'; // Include and initialize the autoloader require_once PATH_LIBRARY_CORE . '/class.autoloader.php'; Gdn_Autoloader::Start(); // Cache Layer Gdn::FactoryInstall(Gdn::AliasCache, 'Gdn_Cache', NULL, Gdn::FactoryRealSingleton, 'Initialize'); // Install the configuration handler Gdn::FactoryInstall(Gdn::AliasConfig, 'Gdn_Configuration'); // Load default baseline Garden configurations Gdn::Config()->Load(PATH_CONF . '/config-defaults.php'); // Load installation-specific configuration so that we know what apps are enabled Gdn::Config()->Load(Gdn::Config()->DefaultPath(), 'Configuration', TRUE); /** * Bootstrap Early * * A lot of the framework is loaded now, most importantly the autoloader, * default config and the general and error functions. More control is possible * here, but some things have already been loaded and are immutable. */