diff options
author | Johannes Ranke <jranke@uni-bremen.de> | 2016-10-06 15:54:47 +0200 |
---|---|---|
committer | Johannes Ranke <jranke@uni-bremen.de> | 2016-10-06 15:54:47 +0200 |
commit | 7b9a52f9bbd38f3b37217f665c9f5654b4b9be1f (patch) | |
tree | 2f89588ceb747978b58ed612b8817adf385f2813 /pelican-bootstrap3/templates | |
parent | b94a9588408d1bf1736880cccbfcdabd68db6649 (diff) | |
download | pelican-themes-7b9a52f9bbd38f3b37217f665c9f5654b4b9be1f.tar.gz |
Set copyright date to modified date of latest article
If this happens to be available, i.e. if the article
has a 'modified' date.
Diffstat (limited to 'pelican-bootstrap3/templates')
-rw-r--r-- | pelican-bootstrap3/templates/includes/footer.html | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/pelican-bootstrap3/templates/includes/footer.html b/pelican-bootstrap3/templates/includes/footer.html index ccd951b..b792835 100644 --- a/pelican-bootstrap3/templates/includes/footer.html +++ b/pelican-bootstrap3/templates/includes/footer.html @@ -3,7 +3,11 @@ <hr> <div class="row"> {% if articles %} - {% set copy_date = articles[0].date.strftime('%Y') %} + {% if articles[0].modified %} + {% set copy_date = articles[0].modified.strftime('%Y') %} + {% else %} + {% set copy_date = articles[0].date.strftime('%Y') %} + {% endif %} {% else %} {% set copy_date = '' %} {% endif %} |