Not sure what I am doing wrong, but cannot seem to add content to a taxonomy term. As a simple start I’ve been trying to add a title, image and description to a “tag”. Is there a suggested way to do this with the Academic theme?
This post Handling taxonomies like a boss - update has an exceptionally clear explanation, but for some reason I can’t get it to work.
Here’s the configuration in config.toml:
[taxonomies]
category = “categories”
tag = “tags”
author = “authors”
title = “titles”
origpublisher = “origpublishers”
origdate = “origdates”
synod = “synods”
In /content/tags/fiction/_index.md
—
title: “Fiction”
description:
This is a very long description text that continues on and on and on.
It has multiple paragraphs, too.
image: “/img/icon-192.png”
—
In /layouts/_default/terms.html
<ul>
{{ range .Data.Pages }}
<li>
<a href="{{ .Permalink }}">{{ .Title }}</a>
<dl>
<dt>Link to the brand page</dt><dd><a href="{{ .Permalink }}">{{ .Permalink }}</a></dd>
<!-- Handling brands that don't have a corresponding page by using 'with' -->
{{ with .Params.description }}
<dt>Description</dt><dd>{{ . }}</dd>
{{ end }}
<!--
Handling brands that don't have a corresponding page by using an 'if' statement.
This let's you add default values to your template.
-->
<dt>Logo</dt>
<dd>
{{ if ne .Params.logo nil }}
<img src="{{ .Params.logo }}" height="90" />
{{ else }}
<img src="http://via.placeholder.com/90x90?text=No+logo" height="90" />
{{ end }}
</dd>
</dl>
</li>
{{ end }}
</ul>
The site repository is here.
Any help greatly appreciated. Thank you.