www.kontakt-bamberg.de/layouts/index.html

20 lines
646 B
HTML
Raw Normal View History

2023-03-11 11:41:19 +01:00
{{ define "main" }}
{{ .Content }}
{{ $pagination := .Paginate .RegularPages }}
{{ with .Content }}{{ with $pagination.Pages }}<hr>{{ end }}{{ end }}
{{ range $pagination.Pages }}
<h1><a href="{{ .RelPermalink }}">{{ .Title }}</a></h1>
{{ .Content }}
{{ if ne .Slug (index (last 1 $pagination.Pages) 0).Slug }}<hr>{{ end }}
{{ end }}
{{ with $pagination }}
{{ if gt .TotalPages 1 }}
<nav class="pagination">
{{ if .HasPrev }}<a href="{{ .Prev.URL }}">&lt; Neuere Posts</a>{{ end }}
<span>{{ .PageNumber }}/{{ .TotalPages }}</span>
{{ if .HasNext }}<a href="{{ .Next.URL }}">Ältere Posts &gt;</a>{{ end }}
</nav>
{{ end }}
{{ end }}
{{ end }}