I ended up using the built in template hierarchy to solve this issue.
Related Posts:
- How to only display posts whose meta_value field is not empty?
- How to print the excuted sql right after its execution
- Find out total number of pages in global query on archive page?
- Resetting post data to previous loop in nested loops
- Order by multiple meta key and meta value [closed]
- Is it possible to completely stop WP_Query retrieving posts?
- How to add taxonomy filter on the query fly?
- Pagination returns 404 after page 20
- Make a WP Query search match exactly the search term
- Make loop display posts by alphabetical order
- Displaying several specific pages using WP_Query()
- How to query posts of standard post format. For real
- Orderby menu_order doesn’t work
- WP_Query by Category Name
- WP-CLI How to generate a list of posts with corresponding meta values
- Query to return maximum of one post per author
- Get attachment by slug
- Warning: urlencode() expects parameter 1 to be string, array given
- Group posts by custom field
- How to get the posts published in last two days using WP_Query?
- getting posts and number by specific meta value in multiple meta
- All sticky posts are returned in custom query
- Get attached media only
- query posts in functions.php and update a field
- get_posts() seemingly ignoring post_type
- If orderby parameter using pre_get_posts is the same for multiple posts what fallback does the query use?
- Can not switch the queried post in pre_get_posts hook
- how to fire join query with post_meta
- Why use JSON API to display recent posts?
- Pagination problem after WP_Query with tag filtering
- Custom Loop in Page Admin Causing Other Fields to Fail
- Pagination stops at page 6
- How to limit total number of posts in wp query loop?
- Get list of terms that have posts in another term
- WP_Query with Metavalue
- Get data of all posts of a query before pagination
- Custom query for sidebar isn’t returning results
- How to vary post loop results layout and resume?
- Using Ajax to load more posts | Help me change the wording on my button to notify the user
- Adding an array from a query string to a WP meta_query
- WordPress add_rewrite_rule() cannot visit lower url levels
- Get a post from other loop each n-posts in the main loop
- Sort by price woocommerce by ID post_meta
- Some doubts about how the main query and the custom query works in this custom theme?
- How to do a wp_query with two acf-fields, sorting on one of them
- Using Advanced Custom Field for file upload, how do I load the file url
- Retrieve posts using thumbnail id as meta key
- Which is faster wpdb & get_row or wp_query & ge_post_meta?
- WP_Query loop else statement not executing
- Modify Search Query if original Query gave no results
- How to cache wp_query with pagination using transients?
- Problem with WP_query
- Why is WP_Query not displaying expected data?
- Filter post query to only show direct children of category
- Highlight current post title on a page
- Why won’t draft listings appear for non-admins?
- has_excerpt() not working inside wp_query
- Apply query arguments after the nth post
- How to properly use AND / OR in custom search
- Get post and its children with WP_Query
- Get every post with value in meta key
- Using get_posts to get posts based on a checkbox value with Advanced Custom Fields
- How do I add a relation parameter to my filter query?
- Searching by title, content and custom taxonomy
- How to get posts by category and by choosing a taxonomy term?
- Paging + WP Query
- Getting the permalink to the latest post from a category
- Paginate pages with dynamic query
- WP_Query loop doen’t work with my custom taxonomy
- Deleting terms from the WordPress wp terms table
- Can I get one wp_query to double order like this?
- In a WP_Query can I force the results’ is_singular() to be set to false?
- My combination of ‘post_type’ and ‘tax_query’ not working?
- Order (by ASC) posts with meta_key so posts without values are last
- Query pages created by deleted users
- how to include orderby value that is empty?
- Get posts that match defined arrays of tags
- WordPress live search and filter
- Why can my filter query SOME metadata but not other metadata?
- The query show user list orderby count published posts in last month
- WordPress – Form does not filter the results of taxonomies
- Pagination Shows Up But Won’t Work on Custom Gallery Page
- How can I use WP_Query to sort ‘event’ custom post type by date?
- Show posts from categories instead of tags
- Sorting Posts by Taxonomy thats not within the query’s $args
- Orderby query does not work for custom fields even with meta query
- Rewind posts then show only first post
- Ordering Posts by parent category, name ascending
- Set Transient on CPT
- Why is $wp_query fetching nothing?
- How to query post into a complex slider
- WP_Query Sorting Posts by month … timeline effect
- When importing a database any page with a wp_query in doesn’t work
- My class function is not seeing GET url paramaters
- Query posts only shows 1
- First post outside of loop, homepage only?
- Filtering product search results using tags
- Using ‘meta_query’ with the ‘pre_get_posts()’ hook disables searching for post titles
- Woocommerce set loop_shop_columns to be 3 in the main shop page loop only and 4 otherwise
- How to save the results of a query as a php file for an autocomplete search bar