From the course: WordPress: Custom Post Types and Taxonomies

Unlock the full course today

Join today to access over 22,500 courses taught by industry experts or purchase this course individually.

Creating an advanced custom taxonomy

Creating an advanced custom taxonomy - WordPress Tutorial

From the course: WordPress: Custom Post Types and Taxonomies

Start my 1-month free trial

Creating an advanced custom taxonomy

- Now that we have a good structural foundation for registering our size taxonomy, let's look at how we can customize it even further. Customizing a taxonomy is very similar to customizing the custom post type. And if we look at the Codex page for register taxonomy, we'll see a lot of the same arguments. There's a label and a labels array, many of the key value pairs for the labels array are exactly the same as the custom post type, and then we have a lot of the same arguments. This is going to make familiarizing yourself with both taxonomies and post types a bit easier. If we go back to our code, the first thing we'll want to do is customize the labels. And in most cases, the labels here will make sense. Add sizes or add new size is a perfectly fine label for our new taxonomy. However, because our taxonomy isn't hierarchical, it takes on the properties and labels of tags, which means that you will see the label add new tag in the dashboard. So let's at least make that change. We'll…

Contents