diff options
author | Stephen Siegert <stephen.siegert@sas.com> | 2019-02-22 18:28:32 +0300 |
---|---|---|
committer | Stephen Siegert <stephen.siegert@sas.com> | 2019-02-22 18:28:32 +0300 |
commit | 9cb94563badb1e434bbc6b9f5e7c7d3b99df5004 (patch) | |
tree | 5be1877ed494c72feb908b82174eaaa24e4db8ee | |
parent | 0f6a9afa26b8bbab1f11bb5a55cdb376ea6549d1 (diff) |
present post single -last mod- info before series links; change presentation
-rwxr-xr-x | exampleSite/content/post/migrate-from-jekyll.md | 11 | ||||
-rw-r--r-- | layouts/post/single.html | 12 |
2 files changed, 13 insertions, 10 deletions
diff --git a/exampleSite/content/post/migrate-from-jekyll.md b/exampleSite/content/post/migrate-from-jekyll.md index 8dd03d5..55784aa 100755 --- a/exampleSite/content/post/migrate-from-jekyll.md +++ b/exampleSite/content/post/migrate-from-jekyll.md @@ -1,8 +1,9 @@ -+++ -date = 2014-03-10 -title = "Migrate to Hugo from Jekyll" -series = "Hugo 101" -+++ +--- +date: 2014-03-10 +title: Migrate to Hugo from Jekyll +series: Hugo 101 +lastmod: 2018-03-10 +--- ## Move static content to `static` diff --git a/layouts/post/single.html b/layouts/post/single.html index 310f7cb..047b088 100644 --- a/layouts/post/single.html +++ b/layouts/post/single.html @@ -19,6 +19,13 @@ {{ .Content }} </article> + <!-- last modified note --> + <span class="f6 gray mv3" title="Lastmod: {{ .Lastmod.Format "January 2, 2006" }}. Published at: {{ .PublishDate.Format "2006-01-02" }}."> + {{ if ne .Lastmod .PublishDate }} + <span class="i">last modified</span> {{ dateFormat "January 2, 2006" .Lastmod }} + {{ end }} + </span> + {{ if and (.Site.Taxonomies.series) (isset .Params "series") }} <section class="mt4"> {{ $readMore := ":wave:" }} @@ -48,11 +55,6 @@ </section> {{ end }} - <span class="f6 gray mt3" title="Lastmod: {{ .Lastmod.Format "January 2, 2006" }}. Published at: {{ .PublishDate.Format "2006-01-02" }}."> - {{ if ne .Lastmod .PublishDate }} - Modified : {{ dateFormat "January 2, 2006" .Lastmod }} - {{ end }} - </span> </section> {{ partial "footer.html" . }} |