mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-23 21:53:09 +02:00
Merge commit '6aa5c9117fd34644459ea9bcfb1b3f5010658d5d'
This commit is contained in:
@@ -135,7 +135,7 @@ videos
|
||||
: an array of paths to videos related to the page; used by the `opengraph` [internal template](/templates/internal) to populate `og:video`.
|
||||
|
||||
weight
|
||||
: used for [ordering your content in lists][ordering]. Lower weight gets higher precedence. So content with lower weight will come first.
|
||||
: used for [ordering your content in lists][ordering]. Lower weight gets higher precedence. So content with lower weight will come first. If set, weights should be non-zero, as 0 is interpreted as an *unset* weight.
|
||||
|
||||
\<taxonomies\>
|
||||
: field name of the *plural* form of the index. See `tags` and `categories` in the above front matter examples. _Note that the plural form of user-defined taxonomies cannot be the same as any of the predefined front matter variables._
|
||||
|
@@ -100,7 +100,7 @@ disableKinds = ["taxonomy","term"]
|
||||
|
||||
{{< new-in "0.73.0" >}} We have fixed the before confusing page kinds used for taxonomies (see the listing below) to be in line with the terms used when we talk about taxonomies. We have been careful to avoid site breakage, and you should get an ERROR in the console if you need to adjust your `disableKinds` section.
|
||||
|
||||
{{< page-kinds >}}
|
||||
{{% page-kinds %}}
|
||||
|
||||
### Default Destinations
|
||||
|
||||
@@ -194,13 +194,13 @@ Currently taxonomies only support the [default `weight => date` ordering of list
|
||||
|
||||
## Add custom metadata a Taxonomy or Term
|
||||
|
||||
If you need to add custom metadata to your taxonomy terms, you will need to create a page for that term at `/content/<TAXONOMY>/<TERM>/_index.md` and add your metadata in it's front matter. Continuing with our 'Actors' example, let's say you want to add a wikipedia page link to each actor. Your terms pages would be something like this:
|
||||
If you need to add custom metadata to your taxonomy terms, you will need to create a page for that term at `/content/<TAXONOMY>/<TERM>/_index.md` and add your metadata in it's front matter. Continuing with our 'Actors' example, let's say you want to add a Wikipedia page link to each actor. Your terms pages would be something like this:
|
||||
|
||||
{{< code file="/content/actors/bruce-willis/_index.md" >}}
|
||||
---
|
||||
title: "Bruce Willis"
|
||||
wikipedia: "https://en.wikipedia.org/wiki/Bruce_Willis"
|
||||
---
|
||||
---
|
||||
title: "Bruce Willis"
|
||||
wikipedia: "https://en.wikipedia.org/wiki/Bruce_Willis"
|
||||
---
|
||||
{{< /code >}}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user