echo "hey, it works" > /dev/null

just enough to be dangerous

Connections theme for Habari updated

To celebrate the release of Habari 0.5, I've updated the Connections theme for Habari and released version 0.2.

As always, comments are extremely welcome. Offers to take over maintenance also appreciated.


  • Change the pagination to the theme function, rather than the deprecated Utils function.
  • Add next and previous navigation on individual posts.
  • Long overdue cleanup of comments, including 'your comment in moderation notice'.
  • Correct the atom feeds in the sidebar.
  • Optimise tags call.
  • Clean up search and fix a bug that occurs when there are no search matches.
  • Use $theme->display() templates instead of include() to be friendlier to plugins.
  • Fix calls to theme functions after updates in core
  • Tweaks to CSS.
  • Reformat all code to meet Habari's code standards.

Comments update on echo

I've updated the comment code in Connections. Feel free to leave a comment and let me know if anything seems awry. If it's bug free, it's probably time I released another version. Boy, am I sick of it though. I really need some time to write a new theme.

Connections for Habari now at 0.1

I've now released version 0.1 of the Connections theme for Habari.This was necessitated by a recent Habari core change that broke the theme, but enough else has been added for this not to be beta any more.

As always, comments are extremely welcome.


  • Increase padding on date so long months don't overflow.
  • When multiple posts are displayed, display the first in full and subsequent posts as excerpts. Comment out the appropriate line in theme.php for all full posts.
  • Nicer handling of tags with no posts.
  • Move post.php to entry.php and only use the template for entries. Pages are now standalone.
  • Change header and footer calls on Theme to prevent killing the site.
  • Removed comment template from page.single.

Connections theme for Habari version 0.1beta

I've just released version 0.1beta of the Connections theme for Habari. I'm happy to move to beta now because I'm actually using it on this site, and have made a lot of updates (0.1alpha was actually pretty badly broken).

Please let me know if you use the theme, or even if you test it.


  • Use the comment content output set up in theme.php
  • Removed redundant tagline from the sidebar
  • Changed class content to id content in entry.multiple (which it should have been all along).
  • Changed post.php so that it does not include the date, and moved the date into appropriate entry templates.
  • Include comments template in page.single.
  • Draft watermark on unpublished entries.
  • Search only outputs date for entries.
  • Don't display a tag in the sidebar if there are no posts with that tag.
  • Only print 'tagged' if there are tags on a post
  • Added template for multiple entries.
  • Fixed strange php error output in 404 template.
  • Added page selector to home page.
  • Fixed search function.
  • Fixed comment form action
  • Add 404 page
  • Changed <code> whitespace to pre.
  • Fixed atom feed.
  • Fixed class names in post.php.
  • Fixed nav pages.

Posts with no category

Now that WordPress comes with tag support, you might have posts that you only want tagged and not categorised. To set that up in the Connections theme, you'll need to set up a category that you don't want displayed (I used 'Uncategorised' and no, I don't live in America, thank you), and edit post.php.

If you enabled tags by following my instructions for enabling tags in Connections, you'll have some code like this:

Posted by <?php the_author(); ?> under
   the_category(' ');
   the_tags(', tagged ', ', ', '');
   edit_post_link(' (edit)');

The call to the function the_category() outputs a link to the category page for each category under which your post is filed. To output categories conditionally you don't want to output them directly, so you need to use the get_the_category function, which returns an array of category objects. I'll ignore the fact that the function calls should really be plural. Replace the code above with the following code.

Posted by <?php the_author(); ?>
   $categories = get_the_category();
   if (!(count($categories) == 1 && 
         $categories[0]->cat_name == 'Uncategorised')) {
     echo " under";
     $category_url = get_option('siteurl') . '/category/';
     foreach ($categories as $category) {
       echo " <a href="\"{$category_url}{$category-">category_nicename}\">";
       echo "{$category->cat_name}</a>";
   the_tags(' tagged ', ', ', '');
   edit_post_link(' (edit)');

Unless there's only one category and it's the one you don't want to display, you want to output the categories. Basically, you need to manually build what the_category builds automatically. Again, I'll ignore the terrible category method naming, some cat_ others category_.

Habari theme Connections 0.1alpha released

I've just released a port of the WordPress Connections theme by Patricia Müller for Habari. At the moment it's an extremely basic and direct port. There is no support for plugins, no blogroll and no archives. If anyone uses it and has any requests, let me know. In fact, if anyone uses it, feel free to let me know.

This is my first Habari theme, so it's probably really crappy. I don't mind if you tell me it's crappy if you do it in a nice way or tell me how to fix it. I did derive some of the theme from Michael Bishop's Mzingi and Sean T. Evans's Aiden's Theme, but the crappy bits are definitely mine.

Thanks to the Habari community, especially to Michael and Sean.