Note

Since this was posted the project has changed it's name to talkatv and the homepage is http://talka.tv.

I have been thinking about developing a commenting service for static pages for a while, and last week I stumbled over a thread on identi.ca discussing the matter. Two days later made the first commit in the repository.

It is built in python, since that's my current native tongue, it utilizes the Flask microframework and various Flask extensions.

The project is called talkatv, currently it has the following features:

Note

The following features have been added since this post was published.

  • Database migrations using mig.
  • Threaded comments.
  • Comment notifications. Both for site owners and comment replies -- Site owners will need to register their domain using /site/add on the talkatv instance. There's no verification for this process yet, so be careful. Last claim site will be the one active.

To embed comments on a page, simply add

  1. <div id="talkatv-comments"></div>
  2. <script>
  3. var talkatv_home = 'http://talka.tv';
  4. // use /talkatv.js instead of /static/js...
  5. var talkatv_shortcut = true;
  6. var talkatv_ordered = true;
  7. document.write(unescape('%3Cscript src="'
  8. + talkatv_home + (window.talkatv_shortcut
  9. ? '/talkatv.js' : '/static/js/talkatv.js')
  10. + '" type="text/javascript"%3E%3C/script%3E'));
  11. </script>

Note

Replace http://talka.tv with your self-hosted application's public URL if you have one. Observe that the default path for talkatv.js is /static/js/talkatv.js. On talka.tv, it's aliased in the nginx configuration

to any HTML page, then apply your styling to the comments, this is the styling I use for the comments on this page:

  1. #talkatv-comments .talkatv-comment-list-wrapper > ol {
  2. margin: 0 0 1.5em 0;
  3. padding: 0;
  4. }
  5. #talkatv-comments .talkatv-comment-list-wrapper ol ol {
  6. margin: 0;
  7. padding: 0 0 0 1.5em;
  8. }
  9. #talkatv-comments form textarea {
  10. width: 100%;
  11. }
  12. #talkatv-comments form {
  13. margin-bottom: 1em;
  14. }
  15. #talkatv-comments .comment-username {
  16. float: right;
  17. }
  18. #talkatv-comments li div.comment-inner {
  19. margin-bottom: 1em;
  20. padding-bottom: 1em;
  21. border-bottom: thin solid #ccc;
  22. }
  23. #talkatv-comments li p {
  24. margin-bottom: .5em;
  25. }
  26. #talkatv-comments a.comment-reply-link {
  27. margin: 0 10px;
  28. }

I should add though, that this software is very immature, I have been working alone (so far) to get it up and working, so that I don't end up in a situation in which I have a solid foundation and then it turns out CORS doesn't forward cookies (which it doesn't, by default. That got me scared for a moment).

There is a lot of room for improvement still, and if you'd like to contribute with anything, join us in #talka.tv on Freenode or communicate via our GitHub page.

With this post I enable talka.tv on all my posts on this site. Feel free to try it out!