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.
This commit is contained in:
Patrick Kollitsch authored and Bjørn Erik Pedersen committed 2019-06-01 11:20:16 +02:00
1 parent 1a44d8a50a
commit a39b9ac871
1 file changed
+2
+2
View File
@@ -46,6 +46,7 @@ For multilingual sites, we also create a Sitemap index. You can provide a custom
This template respects the version 0.9 of the [Sitemap Protocol](http://www.sitemaps.org/protocol.html).
```xml
{{ printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\" ?>" | safeHTML }}
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xhtml="http://www.w3.org/1999/xhtml">
{{ range .Data.Pages }}
@@ -81,6 +82,7 @@ on render. Please don't include this in the template as it's not valid HTML.
This is used to create a Sitemap index in multilingual mode:
```xml
{{ printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\" ?>" | safeHTML }}
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
{{ range . }}
<sitemap>