$attr) {
echo $key . '="' . $attr . '" ';
}
echo '> ';
if ($icon) {
echo '';
if ($content) {
echo $content;
}
echo '';
}
if ($text) {
echo '' . $text . '';
}
if ($click) {
echo '';
} else {
echo '';
}
}
function __init() {
$root = $GLOBALS['webroot'];
// load all core files
require($root . '/core/database.php');
require($root . '/core/aesthetic.php');
require($root . '/core/controller.php');
require($root . '/core/model.php');
require($root . '/core/loader.php');
require($root . '/core/main.php');
require($root . '/core/router.php');
$main = new MainModel();
$load = new Loader();
$router = new Router($main, $load);
$GLOBALS['__vars']['main'] = $main;
$GLOBALS['__vars']['load'] = $load;
$GLOBALS['__vars']['router'] = $router;
$router->handle_request();
};
if (!file_exists('/status/ready')) {
error_page(503, 'Service Unavailable');
}
__init();
?>