Skip to content

Commit

Permalink
Add Flattr button to Sphinx-generated HTML docs
Browse files Browse the repository at this point in the history
  • Loading branch information
earl committed Jul 6, 2011
1 parent c594f25 commit 7bad2ee
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 0 deletions.
7 changes: 7 additions & 0 deletions doc/_templates/donations.html
@@ -0,0 +1,7 @@
<h3>Donate</h3>
<ul>
<li>
<a class="FlattrButton" style="display:none;" rev="flattr;button:compact;" href="http://github.com/earl/beanstalkc"></a>
<noscript><a href="http://flattr.com/thing/156111/beanstalkc" target="_blank"><img src="http://api.flattr.com/button/flattr-badge-large.png" alt="Flattr this" title="Flattr this" border="0" /></a></noscript>
</li>
</ul>
16 changes: 16 additions & 0 deletions doc/_templates/layout.html
@@ -0,0 +1,16 @@
{% extends "!layout.html" %}

{% block extrahead %}
<script type="text/javascript">
/* <![CDATA[ */
(function() {
var s = document.createElement('script'), t = document.getElementsByTagName('script')[0];
s.type = 'text/javascript';
s.async = true;
s.src = 'http://api.flattr.com/js/0.6/load.js?mode=auto';
t.parentNode.insertBefore(s, t);
})();
/* ]]> */
</script>
{{ super() }}
{% endblock %}
1 change: 1 addition & 0 deletions doc/conf.py
Expand Up @@ -33,6 +33,7 @@
'relations.html',
'sourcelink.html',
'searchbox.html',
'donations.html',
]
}

Expand Down

0 comments on commit 7bad2ee

Please sign in to comment.