<?php  
session_start();
$_SESSION['updated'] = false;
ob_start();
// require_once("app/includes/phpmailer/class.phpmailer.php");
require "app/lib/Bootstrap.php";

$app = new Bootstrap();
$visitor = new visitor($app);
$visitor->entry();

require_once("contents/plugins/plugins.php");
$plugins = new plugins();
$plugins->app = $app;
$plugins->load();

$app->process_actions();
$options = new options;
if((!$options->get_option("cron_is_working_on_server", true, 1500) || DEVMODE) && !$_SESSION['updated']) {
	$cron = new cronjobs;
	$cron->check_due_jobs();
}
require_once("contents/themes/theme.php");
$theme = new theme($app);
$theme->load();
$visitor->loaded();
$_SESSION['updated'] = false;
?>