mirror of
https://git.adityakumar.xyz/hugo-theme-introduction.git
synced 2024-11-08 22:49:44 +00:00
Individual taxonomies now display properly as links and the urls are routed correctly to the proper taxonomy term.
Fixes #236
This commit is contained in:
parent
5952da59b1
commit
a90171fdb1
1 changed files with 6 additions and 4 deletions
|
@ -43,11 +43,13 @@
|
|||
</div>
|
||||
{{ end }}
|
||||
{{ range $taxonomy_term, $taxonomy := .Params }}
|
||||
{{ with $.Site.GetPage (printf "/%s" $taxonomy_term) }}
|
||||
<p>
|
||||
{{ with $.Site.GetPage $taxonomy_term }}
|
||||
{{ $len := (len $taxonomy) }}
|
||||
<p>
|
||||
{{ $taxonomy_term | title }}:
|
||||
<a href="{{ .Permalink }}">{{ range $key, $value := $taxonomy }}
|
||||
{{ $value }}</a>
|
||||
{{ range $key, $value := $taxonomy }}
|
||||
<a href="{{ (printf "/%s/" $taxonomy_term) | relLangURL }}{{ . | urlize }}">
|
||||
{{ $value }}</a>{{ if ne (add $key 1) $len }},{{ end }}
|
||||
{{ end }}
|
||||
</p>
|
||||
{{ end }}
|
||||
|
|
Loading…
Reference in a new issue