Custom taxonomies in WordPress

I’ve spent quite a bit of time over the last week getting to grips with custom taxonomies in WordPress, and I’m really pleased with what I’ve found. A taxonomy is a classification, and WordPress already has two taxonomies buil in: tags and categories. Categories lean towards a more formal taxonomy, which you might setup with forethought and some planning, whereas tags lean more towards a more casual folksonomy, which you might construct “on the wing” in a less formal and more ad hoc style. WordPress uses a generic taxonomy setup to create the tag and category taxonomies, and you can use the same functions to create your own taxonomies.

I’m going to take you through the process of creating a basic taxonomy, creating some terms in it and relating those terms to some posts. There’s some demonstration code in the form of a proof of concept WordPress plugin, which you may find helpful.

Continue reading Custom taxonomies in WordPress