diff options
-rw-r--r-- | layouts/_default/terms.html | 2 | ||||
-rw-r--r-- | layouts/partials/header.html | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html index fa91d47..2f432ed 100644 --- a/layouts/_default/terms.html +++ b/layouts/_default/terms.html @@ -3,7 +3,7 @@ <div class="container"> <article> <main> -<h1>{{ .Title }}</h1> +<h1>{{ $.Scratch.Get "Title" }}</h1> <ul class="terms"> {{ range $key, $value := .Data.Terms }} diff --git a/layouts/partials/header.html b/layouts/partials/header.html index bff1bd1..87263fc 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -3,7 +3,8 @@ <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> - <title>{{ .Title }} | {{ .Site.Title }}</title> + {{ $.Scratch.Set "Title" (default .Title (index .Site.Params.text (print "title_" (lower .Title)))) }} + <title>{{ if eq ($.Scratch.Get "Title") .Site.Title }}{{ .Site.Title }}{{ else }}{{ ($.Scratch.Get "Title") }} | {{ .Site.Title }}{{ end }}</title> <link rel="stylesheet" href="{{ "/css/style.css" | relURL }}" /> <link rel="stylesheet" href="{{ "/css/fonts.css" | relURL }}" /> {{ partial "head_custom.html" . }} @@ -28,7 +29,7 @@ {{ end }} {{ end }} {{ else }} - <span>{{ .Title }}</span> + <span>{{ $.Scratch.Get "Title" }}</span> <span>{{ now.Format "2006/01/02" }}</span> {{ $paginator := .Paginate (where .Data.Pages "Section" "!=" "") }} {{ with $paginator }}<span>{{ .PageNumber }} / {{ .TotalPages }}</span>{{ end }} |