diff options
author | Frieder Grießhammer <frieder.griesshammer@der-beweis.de> | 2020-06-01 13:12:28 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-01 13:12:28 +0300 |
commit | 52e6efb5f9c66366b2828c08648e76baa8cf4d03 (patch) | |
tree | 53177171f73d3c61ef200204c740074515f24a39 | |
parent | 40ec547a4c42ea2d894ee9ec42e10d95f0f031f6 (diff) | |
parent | 767ebdfcb399f1872a570de1169b6ec17d01bb2a (diff) |
Merge pull request #11 from rissson/post-meta-add-lastmod-date
Add last modified date to post meta
-rw-r--r-- | layouts/partials/post_meta.html | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/layouts/partials/post_meta.html b/layouts/partials/post_meta.html index 88c07a6..1c8ebdd 100644 --- a/layouts/partials/post_meta.html +++ b/layouts/partials/post_meta.html @@ -8,6 +8,13 @@ {{ .Date.Format (default "02 Jan 06 15:04 MST" .Site.Params.dateFmt) }} </time> ] + {{- if ne .Date .Lastmod }} + <span>Last modified</span> [ + <time datetime="{{ .Lastmod.Format "2006-01-02T15:04:05Z07:00" }}"> + {{ .Lastmod.Format (default "02 Jan 06 15:04 MST" .Site.Params.dateFmt) }} + </time> + ] + {{- end }} {{- end }} {{- if $showlink }} {{- $fallback := slice (dict "Identifier" "Categories") (dict "Identifier" "Series") (dict "Identifier" "Tags") }} |