aboutsummaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
authorMaZderMind2015-03-27 14:21:34 +0100
committerMaZderMind2015-03-31 08:19:08 +0200
commit1a050c087e8f2889b421992350c50fae75a9252b (patch)
tree16cebecacf7063925c1c6e815ed8c3e2927fc829 /index.php
parentf98d93cd1559d48e76366950c51e5a6a1f7a84dc (diff)
error handling
Diffstat (limited to 'index.php')
-rw-r--r--index.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/index.php b/index.php
index a00efc3..b4c87ad 100644
--- a/index.php
+++ b/index.php
@@ -32,8 +32,8 @@ $tpl->set(array(
));
+ob_start();
try {
-
if($route == '')
{
include('view/overview.php');
@@ -135,10 +135,11 @@ try {
}
catch(NotFoundException $e)
{
+ ob_clean();
include('view/404.php');
}
catch(Exception $e)
{
- header("HTTP/1.1 500 Internal Server Error");
- die($e);
+ ob_clean();
+ include('view/500.php');
}