use twitter bootstrap for layouting
[phorkie.git] / www / www-header.php
index 8b99234a0b091216d5129158a93c8030fcffebb4..01214d7e1af7ec307359538ef8ee1e262961b488 100644 (file)
@@ -27,6 +27,9 @@ set_exception_handler(
 );
 
 require_once __DIR__ . '/../data/config.default.php';
+if (file_exists(__DIR__ . '/../data/config.php')) {
+    require_once __DIR__ . '/../data/config.php';
+}
 require_once 'VersionControl/Git.php';
 require_once 'Twig/Autoloader.php';
 \Twig_Autoloader::register();
@@ -42,12 +45,13 @@ $twig = new \Twig_Environment(
 
 function render($tplname, $vars)
 {
+    $vars['css'] = $GLOBALS['phorkie']['cfg']['css'];
     $template = $GLOBALS['twig']->loadTemplate($tplname . '.htm');
     echo $template->render($vars);
 }
 function redirect($target)
 {
-    header('Location: /' . $target);
+    header('Location: ' . $target);
     exit();
 }
 ?>
\ No newline at end of file