From 52e82d9dd6e827227f30a71c1f1a3e96c5e4f78c Mon Sep 17 00:00:00 2001 From: ben Date: Mon, 19 May 2008 08:40:46 +0000 Subject: Elgg will now enter light mode (no plugins are loaded, system init doesn't happen) if the parameter lightmode = "true" git-svn-id: https://code.elgg.org/elgg/trunk@651 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/start.php | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'engine/start.php') diff --git a/engine/start.php b/engine/start.php index af3f20c21..6faf67f12 100644 --- a/engine/start.php +++ b/engine/start.php @@ -30,6 +30,11 @@ } + /** + * Set light mode default + */ + $lightmode = false; + /** * Establish handlers */ @@ -93,11 +98,16 @@ throw new InstallationException("Could not load {$file}"); } + // Determine light mode + $lm = strtolower(get_input('lightmode')); + if ($lm == 'true') $lightmode = true; + // Set default config set_default_config(); - // Load plugins - load_plugins(); + // Load plugins, if we're not in light mode + if (!$lightmode) + load_plugins(); } else { // End portion for sanitised installs only @@ -117,7 +127,8 @@ // Trigger events if (!substr_count($_SERVER["PHP_SELF"],"install.php") && - !substr_count($_SERVER["PHP_SELF"],"setup.php")) { + !substr_count($_SERVER["PHP_SELF"],"setup.php") && + !$lightmode) { // If default settings haven't been installed, forward to the default settings page trigger_event('init', 'system'); if (!datalist_get('default_settings')) { -- cgit v1.2.3