public static function renderTemplate()
{
if (!file_exists(self::getThemePath() . "/index.tpl.php")) {
throw new PubwichError(sprintf(Pubwich::_('The file <code>%s</code> was not found. It has to be there.'), '/themes/' . PUBWICH_THEME . '/index.tpl.php'));
}
foreach (self::$classes as &$classe) {
$classe->init();
}
if (file_exists(self::getThemePath() . "/functions.php")) {
require self::getThemePath() . "/functions.php";
self::applyTheme();
}
include self::getThemePath() . '/index.tpl.php';
}