Categories are not necessary

Ever since I have been using WordPress it has been based on categories. Tags are a relatively new thing, that I have never used, and even newer in the core. Interestingly Habari currently has only tags and I think this difference is quite an interesting one.

Generally people tend to think of categories fairly strict divisions that define the main topic of a post and tags as more specific, but loosly used, labels that are actually closer to index entries than an organisational structure.

The nature of blogs means that it is rarely possible to pre-define the content that will be included and this means that categories often get a little overgrown and need pruning back once in a while. Tags on the other hand are much more fluid and so can be left to grow where they will.

When it all comes down to it though they are both labels that apply to content. The only difference is in the way that we think about them, and use them. In fact the biggest difference is the user interface.

I’ve spent that last month doing little else but organising information and trying very hard not to assign lables to the various parts of the hierarchies so as not to confuse people with terms they expect to refer to something else and even so it has taken me some thought to get my head around the difference, or lack of difference, between tags and categories.

Only using tags (or only using categories) seems to offer a lot of flexibility. It lets you use plugins and naming structures to create hierarchies without the need for WordPress or Habari to actually be written to meet individial needs.

The differences, and uses, of tags and categories are well ingrained in people’s minds now and, let’s be honest, a lot of people do not want to consider their site taxonomy in greater depth than the default provides, but I think it would be interesting to just stop using categories in WordPress and switch to tags. It would certainly simplify some things.

Custom Hooks for Admin Pages

I spent ages trying to find out how to do this. I knew it existed because I read about it but had no idea what to look for to find it. So this is a quick reminder write up.

If you write a plugin that creates an admin page, from WordPress 2.6 (I think) there is a new way to deal with the information the user posts from the form.

In the old days the form handling code would go at the top of the admin page function, or it could be hooked into other actions like the template selector. Now WordPress will create a custom hook.

In the admin page add a hidden form field called ‘action’ with a value of {pluginname}_{action}-{object}; so if you are updating a comment you might use ‘myplugin_comment-update’. You also need to change your form so it posts to admin-post.php.

Admin post will load all the WordPress functions and things, then create a custom hook called: ‘admin_post_’ + your action name. So you can create a new function for handling your form data and trigger it (using the same example) with add_action( ‘admin_post_myplugin_comment-update ‘myfunction’);

It is explained further on this page: http://codex.wordpress.org/Handling_POST_and_AJAX_Requests

Habari and flickr

I decided earlier on that I wanted to have a blog running Habari; it is one thing to write nice things about it and quite another to use it in anger and live with it over time. I mentioned the flickr integration on twitter and more details were asked for so that that is the purpose of this post.

I had started a blog to write about photo techniques (what few I have) but never did much with so this seemed well placed to convert to Habari. I deleted the WordPress files, added Habari and it is up and running.

I haven’t done much to it yet. Over time I will tinker and learn. You can find it here: http://www.eloquium.co.uk

Habari comes with some plugins bundled, two of which I used on the new blog. One is a WordPress database importer which seemed to work well, the other a flickr gallery. I have taken a screencast of the gallery and included it below.

You should note that I haven’t used WordPress to integrate with Flickr so I don’t know what the plugins are like. If you have used them then please drop the name of the plugin and any comparisons you would like to make with the video.

If you haven’t tried Habari, whatever the reason, you should also have a look at my last post where I asked for people’s reasons why they haven’t given Habari a try.

Questions About Habari for WordPress Users

Most of the people that read this blog should be WordPress users and plugin fans so you know what a good blog platform looks like and have your finger on the pulse of blogging software. I hope I have a reasonable cross section of users from experts to novices. So here is my question:

Have you tried Habari? and if not why not?

I have tried most blog platforms, although I will admin that for most of them I haven’t checked back for a while, but I like to play with things, not just to host a blog, but be on the lookout for cool new stuff. I think Habari fits that bill and it is fun using it but it doesn’t seem to have the buzz that I would expect.

Buzz means people, and that means you, so what is stopping you? I would like to know.