At first, not everyone knows, but definetly should know, that there is a pre_get_posts hook which should, in most cases, be used instead of query_posts.
Further, defining only one custom post type results in bringing just one custom post type. It’s correct. When one want to bring both, custom post type and posts, one should use the abbility of post_type param acceptiong array, not only string. Thus, try this code:
function show_mini_feeds_on_home( $query ) {
if ( $query->is_home() && $query->is_main_query() ) {
$query->set( 'post_type', array('post', 'mini-feed') );
}
}
add_action( 'pre_get_posts', 'show_mini_feeds_on_home' );
Related Posts:
- Pagination not working with custom loop
- Get the ID of the latest post
- How to use a custom post type as front page?
- Retrieving 3 latest post from each of 5 different custom post types
- Query for posts in 2 taxonomies
- How to get current post id of a custom post type in a loop using template singel-{custom type}.php?
- ‘category__and’ for custom taxonomy?
- Separate Posts and Custom Post Type in Custom Taxonomy archive template
- How to dynamically build a multiple taxonomy query loop within a post type’s single loop?
- How to insert content from another Custom Post type into Post?
- Change or update WordPress loop based on dropdown selection
- Am unable to reset a query properly
- Get next and previous 3 posts in a term in single post page
- Show a Category X’s custom post type on Category X archive page?
- Different Ways to Query Custom Post Types?
- Listing all term items alphabetically / sorting loop
- pagination not working for category.php (custom post types in categories)
- 3 random images from custom post type, each in a div with a diffrent class
- Control content before and after custom post type loop
- Listing custom post types on archive page with array
- How to conditionally add Custom Post Type to Front Page
- Pagination not working on custom query on a page
- Loop through posts of only 2 statuses
- Custom Post Type not showing in main loop
- postsperpage value not being applied
- Query all post types but limit to parents
- Custom Post Type Query W/Category Dropdown
- Changing WordPress sort order for returned child pages
- Add custom post type to query
- Custom Post Types Not Showing Up In query_posts Result
- Update query based on CPT / Post Type, show all sorted by date
- Shortcode with loop stacks output
- How can I group by Taxonomy on Custom Post Type while filtering out based on custom Meta
- Can I show some specific post rather than latest post?
- Is it possible to add query parameters on the archive page?
- display news with pictures 3 small and one large (loop)
- $post breaking container loop
- Multiple Queries and Loops within CPT Archive
- Query Posts From Multiple Post Types
- Pagination not working with custom loop
- Pagination not working with custom loop
- Pagination not working with custom loop
- Pagination not working with custom loop
- Listing custom post type items from a couple of custom taxonomies
- Pagination not working with custom loop
- How to grab data (titles, thumbnails and custom fields) from multiple posts to populate a new array efficiently?
- How do I correctly query posts from a post ID?
- How to exclude certain portfolios from a loop
- Render a loop in Timber (twig for WordPress)
- show custom post’s post in two different divs [duplicate]
- Display all posts in a custom post type, grouped by a custom taxonomy
- Display a query with multiple post types and same relationship on a single page
- Newer/Older posts links display same posts on every page
- How to solve suspected memory issue in custom WordPress loop?
- Query multiple taxonomy in Custom Post Type
- Query post types with multiple keys
- Comparing timestamps in meta query doesn’t work
- $wpdb returns no results with SELECT query on custom post type, works on default post type
- Problems excluding a custom post-type from the loop
- Get permalink and title by post name?
- Automatically adding meta data to posts or multiple query help
- Conditionally Query Custom Post Types by Post Meta for Blog Home Page?
- reference the current category being used in the category.php page
- Custom Post Type not visible on category page
- Loop through Custom Post Type, and then show children within each iteration
- Archive for custom taxonomy lists all posts instead of current taxonomy
- Querying Two Custom Post Types with OR Not Working
- Best way to style first post differently?
- Posts per row on archive page (custom post type)
- WordPress Loop if/else
- Custon Content within WordPress Loop
- get_post_meta is not working inside shortcode
- Create Array from custom post type to display a slider
- post-per-page and offset not working
- Custom Query: If One Post Object Field Value Is The Same As Another
- Create query for both custom post type and category
- Multiple Loops on a Page Without Duplicates
- Custom taxonomy query showing more than 4 posts
- Loop for custom-post-type comparing taxonomy terms for “related” posts?
- Make bootstrap 5.0 carousel dynamic using ACF and CPT UI [closed]
- Trying to list years (for a filter) but not all years display
- Some posts not displaying by taxonomy term
- WP_Query for custom taxonomies showing posts from non-specified terms?
- WP_Query with all posts in one custom post type and only posts in another custom post type with a specific category
- subtracting the current post form then whole loop, which is generating all CPT titles
- update a posts of other custom post type
- How to return custom posts in loop?
- custom post type loop
- Optimise custom post type queries
- Loop with Custom Post Type and Taxonomies
- How do I get a nested query to only display content that the main query outputed
- WordPress Custom Post Type and sort by Tags
- After rewriting post type’s URL, the number of queries has increased dramatically
- If i have custom post type with 5 custom fields do i have to create a new loop to reference each one?
- Custom Post Type Loop breaking php
- Styling first post using Advanced Custom Fields
- Query custom type posts by array of IDs
- custom post-type query just returns two posts
- Order custom post type is beign ignored
- Assign a tag to custom post type using a query