From d6848ebe6c27b37563dc3dd8f5b14d34ef00ef34 Mon Sep 17 00:00:00 2001 From: Lutz Bender Date: Thu, 30 Nov 2023 09:17:56 +0100 Subject: [PATCH] add custom 404 page --- .htaccess | 7 +++++++ web/error.css | 39 +++++++++++++++++++++++++++++++++++++++ web/error.html | 44 ++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 90 insertions(+) create mode 100644 web/error.css create mode 100644 web/error.html diff --git a/.htaccess b/.htaccess index 6f220f45c4..f3c82b3165 100644 --- a/.htaccess +++ b/.htaccess @@ -1,3 +1,10 @@ + + Header set Cache-Control "no-cache, no-store, must-revalidate" + Header set Pragma "no-cache" + Header set Expires 0 + + RedirectMatch 404 \.conf$ RedirectMatch 404 \.ini$ RedirectMatch 404 \.py$ +ErrorDocument 404 /openWB/web/error.html diff --git a/web/error.css b/web/error.css new file mode 100644 index 0000000000..d3a9529670 --- /dev/null +++ b/web/error.css @@ -0,0 +1,39 @@ +/* prevent scroll gestures */ +body, +html { + overscroll-behavior: none; +} + +body, +html { + border: 0; + margin: 0; + padding: 0; + background-color: black; + color: white; + font-family: Open Sans; +} + +a { + color: inherit; + text-decoration: underline; + font-weight: bold; +} + +.wrapper { + display: flex; + justify-content: center; +} + +#notReady { + display: flex; + flex-direction: column; + padding-top: 10vh; +} + +#logo { + display: flex; + flex-direction: column; + align-content: center; + flex-wrap: wrap; +} diff --git a/web/error.html b/web/error.html new file mode 100644 index 0000000000..c337f49af3 --- /dev/null +++ b/web/error.html @@ -0,0 +1,44 @@ + + + + + + + + + 404 - document not found + + + +
+
+ +
+

Fehler 404: Die aufgerufene Seite wurde nicht gefunden.

+

Bitte aktualisieren Sie ggf. Ihre Lesezeichen.

+

+ Die Startseite erreichen Sie unter + http://[meine-openWB]/. +

+

+ Direkter Zugriff auf die Einstellungen: + http://[meine-openWB]/openWB/web/settings/ +

+
+
+
+ + + + +