From 0a738467bf63b999a9ad14d68b00e36311c314d3 Mon Sep 17 00:00:00 2001 From: Patrick Kollitsch <83281+davidsneighbour@users.noreply.github.com> Date: Sat, 1 Jun 2019 16:01:36 +0700 Subject: [PATCH] Adding required XML tag to sample templates Since Hugo 0.55.0 the XML declaration on XML and RSS files is not added automatically anymore. The samples should reflect that. --- content/en/templates/rss.md | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/content/en/templates/rss.md b/content/en/templates/rss.md index 715bc2a48..08049bfbd 100644 --- a/content/en/templates/rss.md +++ b/content/en/templates/rss.md @@ -58,6 +58,7 @@ copyright = "This work is licensed under a Creative Commons Attribution-ShareAli This is the default RSS template that ships with Hugo. It adheres to the [RSS 2.0 Specification][RSS 2.0]. ```xml +{{ printf "" | safeHTML }} {{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ .Site.Title }}{{ end }} @@ -86,13 +87,6 @@ This is the default RSS template that ships with Hugo. It adheres to the [RSS 2. ``` -{{% warning "XML Header" %}} -Hugo will automatically add the following header line to this file on render. Please do *not* include this in the template as it's not valid HTML. -``` - -``` -{{% /warning %}} - ## Reference your RSS Feed in `` In your `header.html` template, you can specify your RSS feed in your `` tag using Hugo's [Output Formats][Output Formats] like this: