Yes, since WP 3.2 you can set the ‘relation’ arg:
'meta_query' => array(
'relation' => 'OR',
array('key' => '_product_make','compare' => 'LIKE','value' => $strsearch),
array('key' => '_product_model','compare' => 'LIKE','value' => $strsearch)
)
Related Posts:
- Search Custom Post Type with all meta attached?
- Including Custom Meta with posts_where query
- Including metaboxes from custom post types in global search — continued
- Display custom post type for specific user
- Custom Form / Search with Custom Post Type Data
- How can I fetch all the dates from custom fields from various different custom post types and show / list them at one place in ascending order?
- Sort CPT by taxonomy AND THEN by custom field
- How to create a custom search for custom post type?
- Extending the search context in the admin list post screen
- what is the correct way to compare dates in a WP query_posts meta_query
- Advanced search form with filters for custom taxonomies and custom fields
- Multiple orderby values in WP_Query
- don’t publish custom post type post if a meta data field isn’t valid
- AJAX search on post pages by custom post type
- How can I change the admin search posts fields?
- How to make a WP_Query search with custom post types?
- Prevent pre_get_posts filter on specific post type
- Development of a WordPress Search Plugin – Best Practices
- Admin Area Custom Type Search By Meta Fields Without Title & Content
- How do I Paginate Search Results for Custom Post Types?
- WP_Query orderby custom field then post_date in one query
- how to filter by last name for custom post
- Search that will look in custom field, post title and post content
- Filtering a WP_Query meta_query by numeric values isn’t working
- Custom Taxonomy with Custom Post Type Finds No Posts
- Sorting a query by custom field date
- How can I generate a RSS feed based on a custom WP_Query?
- Filtering a WP Query result
- Display Custom Post Type Fields
- Add custom field to media attachment image attribute in post editor
- Search everything (posts, pages, tags, cpt, meta)
- WordPress Search documentation: how to improve search query using taxonomy terms, custom meta fields?
- How to sort CPT by custom meta value (date), and return posts month by month
- Custom Post Type with Custom Title
- How Do I Use WP_Query to Run This Database Query as Search Result?
- Backend search; include CPT meta?
- WP_Query on custom post type not displaying, multiple loops & get_template_part
- Using new WP_Query in shortcode in a custom field causes the main post content to not display
- Search results ordered by custom post types are not grouped
- WordPress query by multiple Custom fields and order by date
- How can I customize “Pages” admin (edit.php) and “Edit Page” admin (post.php) for bulk edit of custom content type?
- Comparing timestamps in meta query doesn’t work
- Display two post types ordered by two custom fields
- Get post info inside modal window?
- WP Query group/order by category name
- Search tags in CPTs
- Having trouble with custom date field for CPT query (WordPress)
- Display posts if a custom field value is equal to another custom field value
- Community and User Generated Content Website: Have been thinking about Drupal but leaning on WordPress heavily
- Sort by two dates. Default entry date and custom field if present
- Impossible to get Attachments Outside WordPress?
- Related links – from other sites
- Search Custom Post Type Custom Fields
- Filtering by Post Meta Custom Fields – Performance
- wp_query to find posts by year and month
- How to create an advanced filter search?
- WP Query—Relationship between two custom post types and their fields
- Custom search for custom post meta with pre_get_posts interferes with WP search
- How to dynamically attach pictures to a carousel
- Assigning the same custom meta box to multiple post types
- Dynamically add / duplicate custom meta in custom post types
- How to insert content from another Custom Post type into Post?
- Get all Posts If has same custom field values in Posts
- Custom Post type and Custom Field WP_Query
- How to structure a site with product variations pages?
- WP_Query: include custom post type only with specific meta value
- WP_Query orderby modified to include custom meta changes
- WordPress custom loop filter by meta_key and value with serialize data
- Returning a list of custom post types excluding those without a specific meta_value
- Two near-identical custom field types – one works, the other doesn’t . What can cause this?
- wp_query check if integer exists in custom field’s array
- search also in taxonomy, tags and custom fields
- How to stick custom post at the top in search results
- Filter custom posts using auto populated dropdown selectors
- How can I get the number of custom post type posts that have a specific attachment image set?
- WordPress sort search results by custom order
- Problem querying Custom post type by custom fields
- Orderby CPT custom fields not working
- WP_Query order by custom field, then randomly order some of results
- Query custom post type with ACF Date
- Query Multiple Custom Posts by Custom Fields
- Get Posts by multiple custom fields is not working
- Order Custom Post Type by Custom Field Value
- WP_Query custom post type query not showing the exact post type
- First custom field value (out of several) displayed twice after query
- Cannot save CPT meta box
- How do i search authors from search form using author’s name
- Possible to filter custom post type with multiple meta data?
- Displaying and searching Custom Posts
- Searching Custom Fields
- Advanced search form with filters for custom taxonomies
- filter search custom field query
- How to let users choose where to search for posts?
- don’t publish custom post type post if a meta data field isn’t valid
- How does order=asc effect a wp_query (its acting pretty weird in a loop)
- Query based on custom fields start and end date
- Redirect to another page using contact form 7? [closed]
- Detect inside a custom query the kind of post type to assign custom classes
- DIsplaying URL of custom field in last post of certain taxonomy && post type
- custom post data – how to