Merge commit '87de22d7464e239c775fbd48ebce1665d5b1e80d'

This commit is contained in:
Bjørn Erik Pedersen
2023-07-29 11:17:28 +02:00
177 changed files with 1623 additions and 1556 deletions

View File

@@ -1,14 +1,14 @@
---
title: Custom 404 Page
linktitle: 404 Page
title: Custom 404 page
linkTitle: 404 page
description: If you know how to create a single page template, you have unlimited options for creating a custom 404.
categories: [templates]
keywords: [404, page not found]
menu:
docs:
parent: templates
weight: 120
weight: 120
weight: 220
weight: 220
---
When using Hugo with [GitHub Pages](https://pages.github.com/), you can provide your own template for a [custom 404 error page](https://docs.github.com/en/pages/getting-started-with-github-pages/creating-a-custom-404-page-for-your-github-pages-site) by creating a 404.html template file in the root of your `layouts` folder. When Hugo generates your site, the `404.html` file will be placed in the root.
@@ -36,7 +36,7 @@ This is a basic example of a 404.html template:
{{ end }}
{{< /code >}}
## Automatic Loading
## Automatic loading
Your 404.html file can be set to load automatically when a visitor enters a mistaken URL path, dependent upon the web serving environment you are using. For example: