Added image support to the sitemap.xml template

Conflicts:
	tpl/template_embedded.go
This commit is contained in:
Derek Perkins 2014-11-24 19:59:26 -07:00 committed by spf13
parent 0be2aade99
commit 3c147bd419

View file

@ -77,6 +77,13 @@ func (t *GoHTMLTemplate) EmbedTemplates() {
<lastmod>{{ safeHtml ( .Date.Format "2006-01-02T15:04:05-07:00" ) }}</lastmod>{{ end }}{{ with .Sitemap.ChangeFreq }}
<changefreq>{{ . }}</changefreq>{{ end }}{{ if ge .Sitemap.Priority 0.0 }}
<priority>{{ .Sitemap.Priority }}</priority>{{ end }}
{{ range .Params.images }}
<image:image>
<image:loc>.src</image:loc>
{{ with .title }}<image:title><![CDATA[.]]></image:title>{{ end }}
{{ with .caption }}<image:caption><![CDATA[.]]></image:caption>{{ end }}
</image:image>
{{ end }}
</url>
{{ end }}
</urlset>`)