is_acting_admin == 0)) { //only admins/acting_admins are allowed to get to the site, //all others get the maintenance view //Note: admins are automatically acting admins $template = new standalonetemplate('_maintenance'); $template->output(); } else { //the default user is anonymous if (!exponent_sessions_loggedIn()) { // Initialize the users subsystem require_once(BASE.'subsystems/users.php'); //TODO: Maxims initial anonymous user implementation //exponent_users_login("anonymous", "anonymous"); } // Initialize the theme subsystem if (!defined('SYS_THEME')) require_once(BASE.'subsystems/theme.php'); if (!DEVELOPMENT && @file_exists(BASE.'install/not_configured')) { header('Location: install/index.php?page=setlang'); exit('Redirecting to the Exponent Install Wizard'); } // Setting $page to an empty value, we do not want to get out // side params to be used when handling subsystems fail. $page = ''; // Handle sub themes $page = ($sectionObj && $sectionObj->subtheme != '' && is_readable(BASE.'themes/'.DISPLAY_THEME.'/subthemes/'.$sectionObj->subtheme.'.php') ? BASE.'themes/'.DISPLAY_THEME.'/subthemes/'.$sectionObj->subtheme.'.php' : BASE.'themes/'.DISPLAY_THEME.'/index.php' ); $base_i18n = exponent_lang_loadFile('index.php'); if (is_readable($page)) { if (IN_AJAX_ACTION == 0) { include_once($page); } else { exponent_theme_runAction(); } } else { echo sprintf($base_i18n['not_readable'], $page); } } $microtime_str = explode(' ',microtime()); $i_end = $microtime_str[0] + $microtime_str[1]; echo "\r\n'; while (ob_get_level() > 0) { ob_end_flush(); } ?>