portable perspectives

a blog about programming, life, universe and everything

Atom Threading Extension FeedFlare

As I was saying in the other article, I implemented a simple dynamic FeedFlare to show the number of comments in your feed, based on the Atom Threading Extensions. The flare provides a link to $yourPageUrl#comments, it could be made more modular if someone needs that.

Basically this means that you need a <link> in your atom feed with rel="replies" and thr:count="123". The flare is not really smart in that it does not take the xmlns declaration into account (yet) so declare it like xmlns:thr="http://purl.org/syndication/thread/1.0".

Experimentally, the flare is available for your own use by using the address:

http://flarez.riffraff.inf/ate/

Just add it through myfeeds->optimize->feedlare. Depending on load the flare may be cached for some hours so don't worry if you don't see updates immediately.

See all comments

How to add Atom Threading Extension to Mephisto

Mephisto, the software that I use for this blog is a great little work.

It doesn't do everything and more, but the default installation provides a very nice administration interface and the most useful functionalities of a blogging system, namely tagging, feeds, comments, and so on. it has a good themeing system, an extensible architecture and a lot of plugins.

The only thing that I believe is missing is a good plugin for syntax highlighting code. There are a couple of them but both support a very restricted set of grammars so I'm not really satisfied and I'm working on a plugin based on vim.

Back to the topic. I always liked FeedBurner's FeedFlares, especially the one that provides comment counting.

That flare is based on RSS' wfw:comments, and basically works by accessing the comment feed linked from the main one and parsing that.

The Atom Threading Extensions allow a more detailed control of this linkage between feeds, more metadata and in the specific, they allow the embedding of the comment count (not only comments, the correct word is "replies") in the main feed, freeing you from the need to parse another feed.

To add this to mephisto you need to change a couple of lines, it would be possible to repackage this as a plugin, but I don't have time to investigate that ATM. In case you want to use this hack, you can see the diff against svn HEAD here

See all comments

AddThis Social Bookmark Button