summaryrefslogtreecommitdiff
path: root/app/controllers/errorController.php
diff options
context:
space:
mode:
authorGravatar Marien Fressinaud <dev@marienfressinaud.fr> 2012-10-21 18:47:57 +0200
committerGravatar Marien Fressinaud <dev@marienfressinaud.fr> 2012-10-21 18:47:57 +0200
commitfb57be5a5af3a2fb46b2dbf2b503ffe78eb5cf49 (patch)
tree9440fc7846d8a56a7005b9ef029669c96ad959aa /app/controllers/errorController.php
First commit
Diffstat (limited to 'app/controllers/errorController.php')
-rw-r--r--app/controllers/errorController.php26
1 files changed, 26 insertions, 0 deletions
diff --git a/app/controllers/errorController.php b/app/controllers/errorController.php
new file mode 100644
index 000000000..3b6f202ab
--- /dev/null
+++ b/app/controllers/errorController.php
@@ -0,0 +1,26 @@
+<?php
+
+class ErrorController extends ActionController {
+ public function indexAction () {
+ View::prependTitle (Translate::t ('error') . ' - ');
+
+ switch (Request::param ('code')) {
+ case 403:
+ $this->view->code = 'Error 403 - Forbidden';
+ break;
+ case 404:
+ $this->view->code = 'Error 404 - Not found';
+ break;
+ case 500:
+ $this->view->code = 'Error 500 - Internal Server Error';
+ break;
+ case 503:
+ $this->view->code = 'Error 503 - Service Unavailable';
+ break;
+ default:
+ $this->view->code = 'Error 404 - Not found';
+ }
+
+ $this->view->logs = Request::param ('logs');
+ }
+}