There seem to be a lot of variations of this type of question, but I have not been able to find one that matches my specific situation or that is less than 4 years old. We have WordPress 4.1.1
- I have a page of Past Conferences.
- Each Past Conference has a year category value.
- The year categories are subcategories of the Past Conferences category.
- On the Past Conferences page, I need the title of each Past Conference.
- I need these conferences grouped by year with the year category name showing.
I have considered wp_list-categories() as it takes a lot of arguments, but this function writes the categories without stopping for the post titles. What I needed is:
[start loop through child categories of the category for that page] print subcategory name [start inside loop through posts in that child category] print post title [end inner loop] [end outer loop]
(I'd love to just write a simple SQL query and be done with it, but I'm trying to use the WordPress functions.)