max.mehl 3 weeks ago
parent
commit
793da3eeaa
No account linked to committer's email address
2 changed files with 9 additions and 1 deletions
  1. 4
    0
      static/.htaccess
  2. 5
    1
      themes/hugo-sustain/layouts/404.html

+ 4
- 0
static/.htaccess View File

@@ -1,10 +1,14 @@
1 1
 RewriteEngine On
2 2
 RewriteBase /
3 3
 
4
+# Redirect old links
4 5
 RewriteRule ^(en|de)/(.*)$ /$2 [R=301,L]
5 6
 RewriteRule ^(en|de)/?$ / [R=301,L]
6 7
 RewriteRule ^about/?$ / [R=301,L]
7 8
 
9
+# Error documents
10
+ErrorDocument 404 /404.html
11
+
8 12
 # Compression
9 13
 AddOutputFilterByType DEFLATE text/plain
10 14
 AddOutputFilterByType DEFLATE text/html

+ 5
- 1
themes/hugo-sustain/layouts/404.html View File

@@ -4,10 +4,14 @@
4 4
       {{ partial "header" . }}
5 5
       <div class="container">
6 6
         <div class="page-not-found">
7
-          <h3>Uh oh! Page not found!</h3>
7
+          <h1>Four-oh-four</h1>
8
+          <h3>Page not found :(</h3>
9
+          <h4>Go back to <a href="/">start</a>.</h4>
8 10
         </div>
9 11
       </div>
10 12
     </div>
11 13
     {{ partial "footer" . }}
14
+    {{ partial "js" . }}
15
+    {{ partial "matomo" . }}
12 16
   </body>
13 17
 </html>

Loading…
Cancel
Save