diff --git a/_sakura/config/config.php b/_sakura/config/config.php index c1d0c7b..09a386f 100644 --- a/_sakura/config/config.php +++ b/_sakura/config/config.php @@ -24,4 +24,4 @@ $fiiConf['urls']['system'] = 'sys.iihsalf.net'; // Errata $fiiConf['etc']['localPath'] = '/var/www/flashii.net/'; $fiiConf['etc']['templatesPath'] = $fiiConf['etc']['localPath'] .'_sakura/templates/'; -$fiiConf['etc']['design'] = 'yuuno'; \ No newline at end of file +$fiiConf['etc']['design'] = 'yuuno'; diff --git a/_sakura/sakura.php b/_sakura/sakura.php index cc53f90..f3a8dcd 100644 --- a/_sakura/sakura.php +++ b/_sakura/sakura.php @@ -40,3 +40,11 @@ set_error_handler(array('Flashii\Flashii', 'ErrorHandler')); // Initialise Flashii Class $flashii = new Flashii\Flashii($fiiConf); + +// Set base page rendering data +$renderData = array( + 'sakura' => [ + 'sakura_version' => SAKURA_VERSION, + 'urls' => $fiiConf['urls'] + ] +); diff --git a/main/index.php b/main/index.php index fbba1a8..5e60a37 100644 --- a/main/index.php +++ b/main/index.php @@ -9,11 +9,10 @@ require_once('/var/www/flashii.net/_sakura/sakura.php'); // Initialise templating engine $flashii->initTwig(); +// Add page specific things +$renderData['page'] = array_merge($renderData['page'], [ + 'title' => 'Flashii Dev' +]); + // Print page contents -print $flashii->twig->render('main/index.tpl', - array( - 'sakura_version' => SAKURA_VERSION, - 'configuration' => $fiiConf, - 'pageTitle' => 'Flashii Even More Nightly :^)' - ) -); +print $flashii->twig->render('main/index.tpl', $renderData);