From 56ffcfff243da0f9087afa28fb0dd183290309b3 Mon Sep 17 00:00:00 2001 From: Thaddee Tyl Date: Sat, 8 Nov 2014 11:54:04 +0100 Subject: [PATCH] Website: 404 page Closes #301. --- 404.html | 14 ++++++++++++++ server.js | 4 ++++ 2 files changed, 18 insertions(+) create mode 100644 404.html diff --git a/404.html b/404.html new file mode 100644 index 0000000000..0488320f4d --- /dev/null +++ b/404.html @@ -0,0 +1,14 @@ +These aren't the pages you're looking + for + +

I have nothing to offer for this request

+

… but blood, toil, tears and sweat. +

+

Fortunately, the main page can offer rainbows instead! +

+ + +(You probably landed on this page because a link was broken, because someone +mistyped its URL, or because of an irrelevant mistake. Don't worry, though: +there is all of the rest of the Web to explore!) + diff --git a/server.js b/server.js index f3a69e40d6..e157ec4e54 100644 --- a/server.js +++ b/server.js @@ -262,6 +262,10 @@ function cache(f) { }; } +camp.notfound(/.*/, function(query, match, end, request) { + end(null, {template: '404.html'}); +}); + // Vendors.