I can only assume that there is filter running on the category page that is overwriting your post type.
- Try adding
'suppress_filters'=>trueto your query arguments, but that only works for some filters not all. I suspect it will not work in this case. - Or find the filter that is altering the query and modify it so that
it does not overwrite existingpost_typearguments, which is what
I assume the filter does.
I expect that option #2 is going to be the solution.
Related Posts:
- Get All IDs Of A Post Type Using WP_Query
- Show all parents and children in custom post type in right order
- wp_query for displaying attachments with a tag
- How can I pick a single post from the latest 3?
- How do I search inside specific taxonomies in WordPress
- How do you determine if a result in a search query is a post or a page?
- Show multiple tax_query from 2 or more post_type in a single code
- paginate_links appearing on page but it doesn’t actually paginate – pagination on a static page with a dynamic `post_type` argument on a static page
- WordPress private post won’t display to other admins
- post_type not working when tag__in is present?
- Issue attempting a wp_query_posts with tags
- Custom query for certain post type OR another post type with a certain category
- Best way to detect if you are in a SINGLE POST page
- How to do a wp_query using “BETWEEN” with two meta_values?
- Better way to get tag stats?
- Query two taxonomies via URL or link?
- How do I order pages and categories by ID or name in the same query?
- wp_query order by title
- Sort posts by custom taxonomy name
- How to adjust found_posts so that it accounts for offset and pagination
- Wp_query order by multiple custom fields?
- Would this post meta be better added to the post table rather than post_meta table
- meta_query on a date range using an array of values
- Pagination for custom query on single.php
- Get product list of given category
- Query Ignoring ‘exclude’ Parameter?
- How to prevent writing duplicate loops?
- merge two query arguments into one WP_Query call
- Adding a parameter to the default query
- Using WP_Query in “parse_query” or “pre_get_post” in Posts2Posts
- Taxonomy search/filter with multiple taxonomies and multiple taxonomy terms
- While creating Block Themes in WordPress, how can I query custom posts for an Archive view?
- How To Fix WP Query Returns Results But Shouldn’t?
- why update and delete query not worked in custom table?
- Weird orderby => post__in issue
- how to handle multiple ajax wordpress queries?
- How to extract specific post
- wp_Qwery works to slow
- Search for “2nd” also returns “22nd” in wp_query
- 2 weeks ago from meta query meta value
- WP_Query returns posts_per_page + 1 every time
- Custom WP query with polylang term
- All posts returned when author of 0 is queried
- Merge two search functions for custom post type
- WP_Query – Accessing MetaValue from Query Result
- problems with comments_number()
- Trying to retrieve random post, getting a page
- get_the_terms – but only show 4 Posts
- Does WordPress have something like Drupal’s DB API?
- PHP – Loop custom post type categories within jQuery Tabs
- How order posts from category by date and comment count?
- Get a list of ACF Repeater-Fields as array
- query_vars empty when using custom url with custom rewrite rule
- Get query results with a page title
- Show single posts date, in a page of posts
- Post archive for certain post format
- Query to get last posts from authors of blog
- Custom Homepage Pagination using WP_Query
- My website is getting too many dierect home arechives and this is increasing my bounce rate
- How to get latest post excerpt from a specific category?
- Get all content on a “single page” site depending on language
- Get list of all Grandchild Pages
- get latest added term from taxonomy and insert into php variable
- Featured images loop for Orbit Slider
- Trouble passing attribute into shortcode function
- WP_Query return posts in wrong order
- Exclude post with taxonomy and from the terms (taxonomy & tag) posts count
- How do i create a custom post query when the meta value is an array?
- How to do WP_User_Query for Nested Array value Inside Nested Array field
- Display the search results like the original pages
- Pagination on archive.php not working?
- How to use jQuery validation to set the search bar to accept only a specific input?
- How to filter on placeholder image
- How to compare between two dates in a nested loop?
- How to query 5 users in random who have published more than 10 posts
- WP query for two post types how to order newest to oldest with two different meta fields?
- Order & Orderby clause not working with custom query
- WP_Query doesn’t works inside loop
- How to redirect a query string to a “virtual” subdirectory
- WP_Query returns images but post_per_page is incorrect
- Problem with custom WP_Query and underlying pagination/posts_per_page
- WP_Query with child element
- Select posts wich has no relationship in custom taxonomy
- WordPress Query posts that have title > another title
- Custom query to order by multiple taxonomies
- Query Posts to fetch Posts with Unique Tag
- Can’t figure out query logic
- Convert a WP Query into a simpler SQL query to fetch only COUNT of posts
- Duplicate posts showing up in loop using infinite scroll
- WP_Query orderby not working on custom post_type
- wp_query->set for several categories
- Getting posts via WP Query
- Print post data inside loop using theme content template
- Where to find WP_Query class?
- How to know which editor published a post programmatically?
- WP_query shortcode inside acf Repeater breaks the repeater loop
- How to short circuit a wordpress query that is not related to posts?
- WP Query order posts not working
- Grab IDs of products from WP_Query which is run elsewhere
- Paginate_Links page 2 doesn’t work