forked from github/pelican
- Added configurable twitter button
Just add a TWITTER_USERNAME='foo' in your settings file
This commit is contained in:
parent
81d2552464
commit
cdd1719334
2 changed files with 5 additions and 2 deletions
|
|
@ -5,7 +5,7 @@
|
|||
<article>
|
||||
<header> <h1 class="entry-title"><a href="{{ article.url }}"
|
||||
rel="bookmark" title="Permalink to {{ article.title }}">{{ article.title
|
||||
}}</a></h1> </header>
|
||||
}}</a></h1> {% include 'twitter.html' %} </header>
|
||||
<div class="entry-content">
|
||||
<footer class="post-info">
|
||||
<abbr class="published" title="{{ article.date.isoformat() }}">
|
||||
|
|
@ -37,4 +37,4 @@
|
|||
|
||||
</article>
|
||||
</section>
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
3
pelican/themes/notmyidea/templates/twitter.html
Normal file
3
pelican/themes/notmyidea/templates/twitter.html
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
{% if TWITTER_USERNAME %}
|
||||
<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-via="{{TWITTER_USERNAME}}">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
|
||||
{% endif %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue