Merge pull request #22 from MrSenko/footer

Make it possible to define custom footer
This commit is contained in:
Gilson Filho 2016-01-18 08:40:48 -03:00
commit dfe1f73df3
3 changed files with 20 additions and 2 deletions

View File

@ -62,6 +62,17 @@ CSS_OVERRIDE = 'myblog.css'
Set ``DISABLE_CUSTOM_THEME_JAVASCRIPT`` to True if you want to disable
``js/clean-blog.min.js`` in case it affects forms and input fields.
### User defined footer
Define ``FOOTER_INCLUDE`` in ``pelicanconf.py`` to insert a custom footer text
instead the default "Powered by Pelican". The value is a template path. You also
need to define the ``EXTRA_TEMPLATES_PATHS`` setting. Example:
```python
FOOTER_INCLUDE = 'myfooter.html'
EXTRA_TEMPLATES_PATHS = [os.path.dirname(__file__)]
```
### Analytics
Accept many analytics:

View File

@ -146,8 +146,11 @@
{% endfor %}
{% endif %}
</ul>
<p class="copyright text-muted">Blog powered by <a href="http://getpelican.com">Pelican</a>,
which takes great advantage of <a href="http://python.org">Python</a>.</p>
{% if FOOTER_INCLUDE %}
{% include FOOTER_INCLUDE %}
{% else %}
{% include 'footer.html' %}
{% endif %}
</div>
</div>
</div>

4
templates/footer.html Normal file
View File

@ -0,0 +1,4 @@
<p class="copyright text-muted">
Blog powered by <a href="http://getpelican.com">Pelican</a>,
which takes great advantage of <a href="http://python.org">Python</a>.
</p>