From what i understand of your question, you are trying to do a meta query. You can do this by the following arguments:
$args = array(
'posts_per_page' => 10,
'post_type' => 'mobile',
'meta_query' => array(
array(
'key' => 'select2_posts',
'compare' => 'LIKE',
'value' => $value_here
)
)
);
You can read more about meta queries here.
Related Posts:
- Can I force WP_Query to return no results?
- meta_query ‘compare’ => ‘IN’ not working
- Use the page slug in a WP_Query?
- Sorting: custom query with orderby meta_value_num THEN by title
- WP_Query and next_posts_link
- paginate_links() adds empty href to first page and previous link
- Using OR conditions in meta_query for query_posts argument
- Get array of posts from the current archive page loop
- Get posts by menu ID
- count posts from custom taxonomy terms by year
- replace the WP_Query class in the main query
- How to grab metabox value in wp_query meta_query key
- Woocommerce query by price range and custom meta key
- Get posts with condition on comment meta value
- WP_Query sort by comment meta data
- Stop all SQL_CALC_FOUND_ROWS wordpress queries
- Move posts to top of WP_Query if in certain Taxonomy?
- WP_query ‘orderby=none’ Problem
- How can I create a WP_Query that returns posts where one meta_value
- ‘paged’ in wp_query doesn’t work
- Sorting meta_value as integer doesn’t work
- Display different number of posts from one category on the different pages
- How to display child posts in the parent category
- Get posts from the Main site to sub site – WordPress MultiSites Network
- Custom Field Query – Meta Value is Array
- How to count data records in wordpress which have same meta_value in wp_postmeta table?
- Get array of current post term ID’s
- WP_Query for showing specific post by id
- Ordering by meta_value AND date NOT WORKING with wp_query
- Transient caching for wp query
- Query by custom dates in UNIX Time
- Custom WP Query from meta_value stored as serialised array
- Get List of all the Authors
- How to check if a post “does not have term” in conditional statement?
- WP_Query returns more results than expected
- Make WP_Query more efficient?
- Set order of returned items in the WP_Query() class/function
- Orderby the sum of several numeric custom meta fields
- unable to retrive parent page information
- Which method is faster to get a single post?
- Site not getting correct featured image from my query
- Using WP_Query within an mu-plugin
- Use more than one query, but prevent duplicates – at scale!
- WP Query related posts by tags
- How to add posts, manually, to a wp_query?
- wp_reset_postdata() does not work as expected
- Search Query for multiple categories using ‘OR’ but having certain categories be ‘AND’
- WP_query with OR relation between args[‘s’] and arg[‘meta_query’]
- add_filter(‘query_vars’) not working in custom template
- Avoid repeated post on page 2 when excluding one on page 1
- Stale $GLOBALS[‘post’] after custom WP_Query empty result set bothers my template, whose fault is this?
- How to count posts with specific arguments
- Why post__not_in is ignored?
- find posts that don’t have a custom taxonomy
- WP Query with multiple tags by get the tags
- Woocommerce pagination and result count after custom loop
- Include latest author posts with pagination in single template?
- Can’t get simple meta queries to work
- How to querry for an item that saved in an array?
- Is it possible to add an argument to a custom function added to a filter hook?
- Order by meta_key doesn’t work
- WP Job Manager plugin – Listing only the twelve job categories on frontpage order by jobs they have
- CPT category post/content is not showing on my page, Please review my coede
- how to get category`s slug in WP_Query loop?
- Trouble building a custom WP_query
- Is there a way to join WP_Query without a filter?
- Multiple meta_key ordering with pre_get_posts
- Category based on post id
- Advise on Templates for Custom Queries
- Query WP Page for Buddypress Group Home [closed]
- How to separate two columns from one content on a page template?
- Get Post Title from different post type based on current loops post_parent using
- WordPress rewrite with custom parameter doesn’t work
- How can I order a post query’s results based on the number of matching taxonomy terms?
- wp query to use both author id and meta_query
- wp_query with meta_query and tax_query
- WordPress live search and filter custom fields
- Avoid removing duplicate posts
- Select multiple categories with is_tax
- Repeat array inside array through while loop
- Using modified ‘meta_key’ to set ‘orderby’ in WP_Query?
- get last child post by wp_query
- WP_Query don’t working with fixed post_id and term_taxonomy
- Combine WP_Query with array of custom data to single loop without breaking the pagination
- Query posts in current category but not attachment format
- WP_Query with Pagination and orderby meta_value_num showing duplicates
- Create multiple sections for all categories and then queries all the posts for each of those categories
- Using orderby with 2 meta keys
- wp_query – Modify $query to include duplicate content
- Optimising specific Query with ACF meta objects
- Query to get all the posts of more than 2 meta_value having same meta_key?
- Slow getting posts from category
- WP Query get posts by specific author IDs if one of several logged in authors
- Query specific number of posts for each post type in specific order
- Avoiding page loop
- Query Users by post count, last 30 days and display each users post count according to post type
- how do I exclude child categories from a wp_query?
- How to create a loop inside WP_Query?
- how to show only catergory titles on a page in wordpress
- How to efficiently find “duplicate” posts, where the titles are different, using metadata to match posts?