diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2022-04-28 12:52:15 +0300 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2022-04-28 12:52:15 +0300 |
commit | 4852a3765343c5df5c147b54b8e7ab45d1d9ed33 (patch) | |
tree | 469c8c3e0373537159d182a6dec872744558cbaa /docs/content/en/templates | |
parent | fa80fe3c8ab523846178f94fdc65c997d8eef10c (diff) | |
parent | 3902f9a4767fe6e62ac5146728d8311b8cd227e0 (diff) |
Merge commit '3902f9a4767fe6e62ac5146728d8311b8cd227e0'
Diffstat (limited to 'docs/content/en/templates')
-rw-r--r-- | docs/content/en/templates/404.md | 1 | ||||
-rw-r--r-- | docs/content/en/templates/lists.md | 7 | ||||
-rw-r--r-- | docs/content/en/templates/render-hooks.md | 2 | ||||
-rw-r--r-- | docs/content/en/templates/single-page-templates.md | 2 | ||||
-rw-r--r-- | docs/content/en/templates/taxonomy-templates.md | 8 |
5 files changed, 14 insertions, 6 deletions
diff --git a/docs/content/en/templates/404.md b/docs/content/en/templates/404.md index a2d06cf81..c638d89fa 100644 --- a/docs/content/en/templates/404.md +++ b/docs/content/en/templates/404.md @@ -54,6 +54,7 @@ Your 404.html file can be set to load automatically when a visitor enters a mist * Caddy Server. Use the `handle_errors` directive to specify error pages for one or more status codes. [Details here](https://caddyserver.com/docs/caddyfile/directives/handle_errors) * Netlify. Add `/* /404.html 404` to `content/_redirects`. [Details Here](https://www.netlify.com/docs/redirects/#custom-404) * Azure Static website. You can specify the `Error document path` in the Static website configuration page of the Azure portal. [More details are available in the Static website documentation](https://docs.microsoft.com/en-us/azure/storage/blobs/storage-blob-static-website). +* DigitalOcean App Platform. You can specify `error_document` in your app specification file or use control panel to set up error document. [Details here](https://docs.digitalocean.com/products/app-platform/references/app-specification-reference/). {{% note %}} `hugo server` will not automatically load your custom `404.html` file, but you diff --git a/docs/content/en/templates/lists.md b/docs/content/en/templates/lists.md index ace5d6ab9..97dc0f40d 100644 --- a/docs/content/en/templates/lists.md +++ b/docs/content/en/templates/lists.md @@ -421,6 +421,8 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{< /code >}} +{{< new-in "0.97.0" >}} `GroupByDate` accepts the same time layouts as in [time.Format](/functions/dateformat/) and The `.Key` in the result will be localized for the current language. + ### By Publish Date {{< code file="layouts/partials/by-page-publish-date.html" >}} @@ -438,6 +440,7 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{< /code >}} +{{< new-in "0.97.0" >}} `GroupByDate` accepts the same time layouts as in [time.Format](/functions/dateformat/) and The `.Key` in the result will be localized for the current language. ### By Lastmod @@ -456,6 +459,8 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{< /code >}} +{{< new-in "0.97.0" >}} `GroupByDate` accepts the same time layouts as in [time.Format](/functions/dateformat/) and The `.Key` in the result will be localized for the current language. + ### By Expiry Date {{< code file="layouts/partials/by-page-expiry-date.html" >}} @@ -473,6 +478,8 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{< /code >}} +{{< new-in "0.97.0" >}} `GroupByDate` accepts the same time layouts as in [time.Format](/functions/dateformat/) and The `.Key` in the result will be localized for the current language. + ### By Page Parameter {{< code file="layouts/partials/by-page-param.html" >}} diff --git a/docs/content/en/templates/render-hooks.md b/docs/content/en/templates/render-hooks.md index 8f1a55c2f..6987819ca 100644 --- a/docs/content/en/templates/render-hooks.md +++ b/docs/content/en/templates/render-hooks.md @@ -13,7 +13,7 @@ menu: weight: 20 --- -{{< new-in "0.62.0" >}} Note that this is only supported with the [Goldmark](#goldmark) renderer. +{{< new-in "0.62.0" >}} Note that this is only supported with the [Goldmark](/getting-started/configuration-markup#goldmark) renderer. You can override certain parts of the default Markdown rendering to HTML by creating templates with base names `render-{kind}` in `layouts/_default/_markup`. diff --git a/docs/content/en/templates/single-page-templates.md b/docs/content/en/templates/single-page-templates.md index 55e267d38..b6d8241c2 100644 --- a/docs/content/en/templates/single-page-templates.md +++ b/docs/content/en/templates/single-page-templates.md @@ -83,7 +83,7 @@ To easily generate new instances of a content type (e.g., new `.md` files in a s [dry]: https://en.wikipedia.org/wiki/Don%27t_repeat_yourself [`.Format` function]: /functions/format/ [front matter]: /content-management/front-matter/ -[pagetaxonomy]: /templates/taxonomy-templates/#displaying-a-single-piece-of-content-s-taxonomies +[pagetaxonomy]: /templates/taxonomy-templates/#display-a-single-piece-of-contents-taxonomies [pagevars]: /variables/page/ [partials]: /templates/partials/ [section]: /content-management/sections/ diff --git a/docs/content/en/templates/taxonomy-templates.md b/docs/content/en/templates/taxonomy-templates.md index a265b68d0..27fadb85b 100644 --- a/docs/content/en/templates/taxonomy-templates.md +++ b/docs/content/en/templates/taxonomy-templates.md @@ -25,8 +25,8 @@ Hugo includes support for user-defined groupings of content called **taxonomies* Hugo provides multiple ways to use taxonomies throughout your project templates: -* Order the way content associated with a taxonomy term is displayed in a [taxonomy list template](#taxonomy-list-template) -* Order the way the terms for a taxonomy are displayed in a [taxonomy terms template](#taxonomy-terms-template) +* Order the way content associated with a taxonomy term is displayed in a [taxonomy list template](#taxonomy-list-templates) +* Order the way the terms for a taxonomy are displayed in a [taxonomy terms template](#taxonomy-terms-templates) * List a single content's taxonomy terms within a [single page template][] ## Taxonomy List Templates @@ -37,7 +37,7 @@ Taxonomy list page templates are lists and therefore have all the variables and See [Template Lookup](/templates/lookup-order/). -## Taxonomy Terms Template +## Taxonomy Terms Templates ### Taxonomy Terms Templates Lookup Order @@ -103,7 +103,7 @@ type WeightedPages []WeightedPage ## Displaying custom metadata in Taxonomy Terms Templates -If you need to display custom metadata for each taxonomy term, you will need to create a page for that term at `/content/<TAXONOMY>/<TERM>/_index.md` and add your metadata in its front matter, [as explained in the taxonomies documentation](/content-management/taxonomies/#add-custom-meta-data-to-a-taxonomy-term). Based on the Actors taxonomy example shown there, within your taxonomy terms template, you may access your custom fields by iterating through the variable `.Pages` as such: +If you need to display custom metadata for each taxonomy term, you will need to create a page for that term at `/content/<TAXONOMY>/<TERM>/_index.md` and add your metadata in its front matter, [as explained in the taxonomies documentation](/content-management/taxonomies/#add-custom-metadata-to-a-taxonomy-or-term). Based on the Actors taxonomy example shown there, within your taxonomy terms template, you may access your custom fields by iterating through the variable `.Pages` as such: ```go-html-template <ul> |