Unlock your potential with a Pro Membership
Here is where you propel your career forward. Come join us today. Learn more.
Render Entry Footer Terms
Lab: WordPress Custom Taxonomy Basics
Video Runtime: 08:40
Did you notice how the categories and tags were listed under each post? But for the ones that have a department, those are not showing up. That’s because we need to add the department terms to the Genesis entry footer, i.e. the footer’s post meta.
In this episode, you and I are going to explore the Genesis framework. You’ll learn about the [post_terms]
shortcode available to you in Genesis and how to customize its user-defined attributes to add the taxonomy and text before the labels. You’ll learn about the genesis_post_meta
filter event too, as you will register a callback and then take a deep dive into its processing.
Here is the department taxonomy term rendered into the entry footer of a post:
Here it is for a team bio single:
-
Want to cheat and see the code you're building? Click here
Did you know that Genesis has a post terms shortcode?
Fun fact: The Genesis framework has quite a few shortcodes built into it. We are using the [post_terms]
and then setting the taxonomy and before attributes like this:
[post_terms taxonomy="department" before="Department: "]
This episode will show the Genesis code and walk you through how to use it.
Because we are doing some PHP, I broke this episode up into multiple parts with 2 PHP lessons in the middle.
Code. Eat. Code. Sleep. Dream about Code. Code.
Episodes
Total Lab Runtime: 01:30:53
- 1 Lab Introductionfree 08:15
- 2 Custom Taxonomy - The What, Why, and Whenfree 08:32
- 3 Registering a Custom Taxonomypro 09:54
- 4 Configure the Labelspro 14:51
- 5 Bind to Post Typespro 11:55
- 6 Configuring Argumentspro 07:52
- 7 Render Entry Footer Termspro 08:40
- 8 PHP 101: Concatenating Assignment Operatorpro 02:26
- 9 PHP 101: Building Stringspro 08:19
- 10 Test Entry Footer Termspro 03:03
- 11 Flush Rewrite Rulespro 03:56
- 12 Wrap it Uppro 03:10