{{ define "main" }} <header> <h2>{{ .Title }}</h2> <p>{{ .Description }}</p> {{ if .Site.Params.show_post_dates | default true }} {{- with .Date }}<time>{{ . | time.Format ":date_medium" }}</time>{{ end }} {{ end }} {{ partial "tags.html" . }} </header> {{- if or .Params.image }} {{- $featimg := "#" -}} {{- if .Params.image -}} {{/* se è stata definita un'immagine featured */}} {{- $img := .Page.Resources.GetMatch .Params.image -}} {{- $featimg = $img.RelPermalink -}} {{- end -}} {{- if .Params.featured -}} {{/* se è stata definita un'immagine featured */}} {{- $img := .Page.Resources.GetMatch .Params.featured -}} {{- $featimg = $img.RelPermalink -}} {{- end -}} <span class="image featured poppo"><img src="{{ $featimg }}" alt="{{ .Params.image_alt }}" /></span> {{ end }} {{- .Content }} {{ end }}