From 1509f660231319cf3da4a6559de826e4786005bd Mon Sep 17 00:00:00 2001 From: Dennis Eriksen Date: Tue, 26 Mar 2013 12:39:34 +0100 Subject: added 404 --- routes/router.js | 21 +++++++++++++++++++++ views/error/404.ejs | 10 ++++++++++ 2 files changed, 31 insertions(+) create mode 100644 views/error/404.ejs diff --git a/routes/router.js b/routes/router.js index 11d45bb..d0442b8 100644 --- a/routes/router.js +++ b/routes/router.js @@ -40,4 +40,25 @@ module.exports = function(app) { }); + /* + * 404 ERROR + */ + + app.get('*', function(req, res) { + res.render('error/404', { title: 'Fant ikke siden' }); + }); + + + + + + + + + + + + + + } diff --git a/views/error/404.ejs b/views/error/404.ejs new file mode 100644 index 0000000..22ba15d --- /dev/null +++ b/views/error/404.ejs @@ -0,0 +1,10 @@ +<% include ../header %> + + + +

<%= title %>

+

Velkommen til <%= title %>

+

Her kommer det kanskje mer senere.

+ + +<% include ../footer %> -- cgit v1.2.3