From the course: WordPress: Custom Post Types and Taxonomies
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Creating an advanced custom taxonomy - WordPress Tutorial
From the course: WordPress: Custom Post Types and Taxonomies
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…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
(Locked)
Building a basic custom taxonomy4m 14s
-
(Locked)
Creating an advanced custom taxonomy2m 50s
-
(Locked)
Activating the REST API for your taxonomy1m 17s
-
(Locked)
Adding taxonomy terms to your post types1m 43s
-
(Locked)
Challenge: Make location taxonomy1m 13s
-
(Locked)
Solution: Make location taxonomy3m 10s
-
(Locked)
-
-
-
-