Skip to content
Snippets Groups Projects
Commit f002e631 authored by Torsten Grote's avatar Torsten Grote
Browse files

Merge branch '17-latest-news' into 'master'

Link to latest news item, not news index page

Closes #17

See merge request !42
parents bbd9e0eb b2fba416
No related branches found
No related tags found
1 merge request!42Link to latest news item, not news index page
{{ define "main" }} {{ define "main" }}
<h2>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h2> <h2>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h2>
<p><strong>Latest News:</strong> <p><strong>Latest News:</strong>
{{ range first 1 (where .Pages "Section" "news").ByDate.Reverse }} {{ range first 1 (where .Site.RegularPages "Section" "news").ByDate.Reverse }}
<a href="{{.Permalink}}">{{.Title}}</a> <a href="{{.Permalink}}">{{.Title}}</a>
</p> </p>
{{ end }} {{ end }}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment