In the WPDevDesign Facebook group, a user asked:

In this members-only tutorial, we shall

  • loop through all the terms of a book_category taxonomy
  • construct a meta query array wherein a date_live date field added using ACF is checked for its value between the first and last days of the current month
  • for each taxonomy term create a WP_Query object having all the entries of the book post type that belong to that term AND meeting the above meta query requirement i.e., the month of date-type custom field's value matching the current month.
  • output the taxonomy term headings and book titles in the loop

to have entries of a CPT grouped by a taxonomy where the date-type custom field's value falls in the current month.

Here's the Code

This is a premium members-only content.

To view the rest of the content, please sign up for membership ($47/month or $399 one-time).

Already a member? Log in below or here.

Need help implementing a tutorial in your site or want to hire me for custom work?


Find the article helpful and wish to donate?



You need to be logged in to view and post comments.
Not a member yet? Join here.
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram
%d bloggers like this: