Short answer: no.
But if you want to use one loop for all your needed posts, you can do something like this:
$args = array(
'post_type' => 'product',
'meta_query' => array(
array(
'key' => 'cf_type',
'value' => 'fog', // need to have 10 with value 'fog' and 10 with value 'gof'
)
),
'numberposts' => 10,
'orderby' => 'modified',
'order' => 'desc',
'fields' => 'ids'
);
$postsfog = get_posts($args);
$args['meta_query'] = array(array('key' => 'cf_type','value' => 'gof');
$postsgof = get_posts($args);
$myloopposts = get_posts(array(
'posts_per_page' => -1,
'posts__in' => array_merge($postsfog,$postsgof)),
'post_type' => 'product',
'orderby' => 'post__in',
'ignore_sticky_posts' => true
));
Related Posts:
- Query Multiple Custom Posts by Custom Fields
- Group by custom field value (start and end times)
- Orderby meta_key/meta_value not displaying anything, am I overlooking anything?
- Advanced search form with filters for custom taxonomies and custom fields
- Help Creating a Slideshow Custom Post Type with Custom Meta Boxes?
- Search multiple custom fields by using meta_query
- Custom Post Type – Taxonomy Dropdown Menu?
- How do I implement custom fields without using any plugins?
- How I check if the same post slug has not been used before publishing?
- How to sort a table of custom posts by column containing custom field
- order by meta_value serialized array
- convert Custom Fields Option-Values to Tags/Taxonomy
- Custom post metadata not appearing in public API
- Automatically Insert Custom Field on Custom Post Type Publish
- Display custom post types with custom date field value (before today) & order by custom date field
- How to have the right design for a custom post type without accessing themes
- How to add the post ID (or any other post data) to a Contact Form 7 mail?
- Create a post in custom post type using field in registration form after users submit form
- WordPress custom meta field for custom post not storing data
- Conditional regex in add_rewrite_rule() for specific query filters & pagination
- List all images from a single post meta value
- Publish an XML feed from a CPT with ACF fields?
- WP_Query: include custom post type only with specific meta value
- Is there a way to get a file URL from the relationship ACF field?
- Want to Add Custom Fields for Uploading video to WordPress Users from front end
- Meta Key Value in current-user-only loop
- How can I dynamically add a post to a custom post type which uses a custom field?
- dynamically add a custom field or metabox to custom post type [duplicate]
- How to implement a Google map store locator
- Random image from tag/custom type on sidebar
- retrieve Meta field value from CPT and set those values as Image Meta Field “Title”
- Set a maxlength for the title input in a custom post type
- Update Post Meta for a logged in user
- Problem querying Custom post type by custom fields
- Using custom field content as expression in IF statement [closed]
- ACF From & To Date Validations
- Woocommerce custom field search in custom post type [closed]
- Custom REST endpoints for a custom post type with custom fields
- Homepage’s content is dependent on the custom field values (set automatically), how do I get homepage to update without manually updating page?
- Meta Query posts not showing on ending date of custom field
- Cross reference custom post types
- frontend image post uploader
- Custom Post Fields at the beginning of a Custom Permalink
- Possible to filter custom post type with multiple meta data?
- Show fields based on taxonomy selection in editor
- Permalinks: custom structure for taxonomy – tags?
- How to Get the title of a custom field?
- Create custom post with meta field with AJAX and the WordPress REST API
- Specifying meta field’s column type in Database using add_post_meta
- How to customize work area / admin area in a custom post type without plugins?
- ACF in wordpress
- delete_post_meta() for whole CPT / multiple posts?
- How to inherit field value from parent post into in child / sub post
- hide specific div on single.php [closed]
- How to get_term_meta on single custom post?
- How do you output an unknown number of images in a custom post type with desired markup?
- How to fetch custom post types with its full data on wordpress?
- Custom Fields not showing up for custom post type
- Custom post type in Custom widget – $listItem
- Generating and downloading files with WP API
- Why the_excerpt() function returns excerpt on the Home page and trimmed content in sidebar?
- Add a class to post_class if more than one post shares same meta_value_num
- Add a meta field to the list of results for a custom post type
- Front-end Image Upload to Custom Meta Box
- How do I list a custom field and custom taxonomies for each result in a loop?
- Getting the list of the latests posts and custom type posts in the homepage
- Custom fields for post or terms which don’t update on post update
- order the meta query results by 2 custom fields
- ACF – Retrieve custom taxonomy from a relationship field
- How to Print Title and Permalink of CPT Post behalf of Posts Meta Value with WP_Query
- Query custom post type that has a serialized relational advanced custom field value
- Updating a custom post status after an expiry date rather than trashing it
- How can I query and sort custom-post type using WP_Query
- Meta query and compare “!=” not working as expected
- How to add dynamic fields on wordpress custom post type page in admin section
- How can I add a meta[] to my custom post type and search by term with the Rest API?
- Creating an archive page or simple template to list all values of a custom field of specific post type listing
- How to Disable option of meta field if that option is selected for any other post in custom post type?
- Run query on specific admin options page and send results to select field in another function
- get_previous_post_link and get_next_post_link of custom post type that share custom field value
- Error get_posts with Custom Taxonomy and OR relation
- Automatically assign posts with custom field to taxonomy term
- Attach several custom posts to one meta field
- Error in WP Query. If variable is empty it is displaying previous post value
- Show first posts with custom field not empty and order all by title
- Certain number of posts with certain excerpt length
- Setting a custom $query->query_vars[‘meta_key’] breaks the WordPress menu
- WP_Query and two custom fields returns no posts
- Is it good practice to search for custom posts based on custom field values?
- Custom post type with custom fields enabled, is there a way to set a default group of fileds?
- Storing/querying custom date data
- I want to split this into two functions
- Repeatable Custom Field for Media Upload
- How to store datetime from custom meta box so that it can be sorted by
- Custom Post Meta on a Different Page?
- show custom post’s post in two different divs [duplicate]
- Adding a custom field after post title (ex.Example Title [30 Second Read])
- Creating post custom field text area
- querying to custom field over ACF REST API
- Custom Sort Order for Custom Post Type Taxonomy