From c4994cc895cd5b0c7432fd112cbb65092dc72362 Mon Sep 17 00:00:00 2001 From: Victoria Drake Date: Mon, 22 Jun 2020 12:01:05 -0500 Subject: Un-markdownify Page titles - Prevent rendered HTML from showing up in tab and title bar for titles that use Markdown Address #219 --- exampleSite/content/en/blog/long-form-post.md | 2 +- layouts/partials/head/metadata.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/exampleSite/content/en/blog/long-form-post.md b/exampleSite/content/en/blog/long-form-post.md index fafd351..b15867e 100755 --- a/exampleSite/content/en/blog/long-form-post.md +++ b/exampleSite/content/en/blog/long-form-post.md @@ -1,5 +1,5 @@ --- -title: "_Long_ Form Post" +title: "**Long** Form Post!" date: 2020-05-30T20:18:53-05:00 showDate: true draft: false diff --git a/layouts/partials/head/metadata.html b/layouts/partials/head/metadata.html index 7481c1c..fc624d2 100644 --- a/layouts/partials/head/metadata.html +++ b/layouts/partials/head/metadata.html @@ -6,7 +6,7 @@ {{ if .Site.Params.description }}{{ end }} -{{ .Title | markdownify }}{{ if ne .Title .Site.Title }} - {{ .Site.Title | markdownify }}{{ end }} +{{ .Title | humanize | title }}{{ if ne .Title .Site.Title }} - {{ .Site.Title | markdownify }}{{ end }} {{ with .OutputFormats.Get "RSS" }}{{ end }} -- cgit v1.2.3