I am not sure from your wording if you hadn’t tried it with query argument or it didn’t work?
$the_query = new WP_Query(array( 'meta_key' => 'open', 'meta_value' => 'yes' ));
Custom Field Parameters in Codex.
Related Posts:
- How to filter a dd/mm/yyyy date from a custom field in a query
- WP_Query – Order results by meta value
- Add filter menu to admin list of posts (of custom type) to filter posts by custom field values
- Query to sort a list by meta key first (if it exists), and show remaining posts without meta key ordered by title
- Filter by one custom field, order by another?
- Is there any action filter/hook for validating a custom field before publishing the post?
- Can I query custom meta data through WP_Query
- Apply the_content filter to a custom field with multiple values
- Meta Query with AND & OR?
- Pass all custom fields through the same filter on post load?
- How do I search an array stored in a custom-field using WP_Query?
- Filter results with custom field values and dropdown
- How do I order by multiple custom fields using wp_query?
- Archive sorting functions by custom fields (front-end)
- Trying to perform complex custom field query with order by set to field value
- Query meta field using between
- Order Posts by Closest Numeric Values
- 2 orderby in wp_query with 2 custom fields
- Can serialized arrays in DB be matched against serialized arrays with meta_query?
- How to get a meta value from all post
- Change content before writing to database
- WordPress Search Custom Meta Field Only
- Compare meta_query decimals not working right
- How do I assign this filter to a variable? (Appending php & markup to the_content)
- WP_Query multiple use of relation and/or
- Query Problem – Show posts within category ‘x’ that have a custom field between ‘y’ and ‘z’
- Using custom fields in a filter hook
- Add an advert every nth Paragraph
- Using OR in WP_Query negates the “NOT EXISTS” compare
- WP_query : meta_key with custom rule for specific value
- How can I combine meta_query queries?
- Using WP Query to search by multiple meta fields
- Difference between ‘LIKE’ and ‘IN’ in meta queries
- Compare WP Custom Field date
- Sort by posts that have a featured image?
- WP_Query display next custom post from today’s date
- Order by value in serialized custom field
- $wp_query meta_key naming issue [closed]
- Author Page Custom Query WHERE author OR [post meta value] OR [post meta value]
- Meta_query and numeric comparison [closed]
- Force hide custom field metaboxes
- Saving custom profile fields
- Adding Custom Fields to Search
- Upcoming Event: How do I sort database by custom date field, but ignore past dates?
- Any way to include custom fields in WP_Query results?
- Update posts after populating ACF field value [closed]
- How to validate custom field on lost password form before the user id field?
- Multiple relationships in a query
- WP Query Returning All Posts
- How do I use wp_query for WordPress search?
- Meta query with timestamp using WP_query
- Conditional custom field query
- Order query by meta_value with multiple custom fields
- Auto Populate Custom Field with Complex Value That Increase by One?
- filtering custom post types via meta data drop down
- global function to apply filter to custom field
- How to order posts by one custom field and filter them by another one?
- Filter multiple custom fields Values with Check boxes
- How to get categories with posts by custom field value?
- Custom WP_Query for WordPress Search Results with meta_query
- Meta Query And/Or
- How to combine custom fields to make one order-able value
- Redirect to another page using contact form 7? [closed]
- How to Wrote Simple Calculations by Using Custom Fields in Loop?
- Passing meta_box string to post__in?
- Best filter to use for modifying custom fields on a post?
- Query post by date (stored custom field meta as yyyymmdd) and differentiate across 12 months
- meta_value and meta_key filtering returning no posts [closed]
- How to display childrens custom fields?
- Select custom posts by meta_value and sort by a different meta value
- Can’t query by meta_key
- Adding custom field and querying from post table
- Access ACF fields within custom preview function?
- Sort posts by clicks on download button
- Retrieve select tag custom values from array and display them in current page with wp_query?
- How to use a dropdown to filter posts by custom field
- Let Users Filter Posts by Custom Fields
- Meta query relation ‘OR’ not working as expected
- The best way to collision check in WP
- WP_query multiple custom fields not working
- Custom Theme Fields in Settings Menu – apply filters to one of those fields?
- Footnotes in custom fields
- How to change permalink on headlines in rss feeds?
- How to change order of posts in admin
- Custom Query Fields – Altering Meta Value
- How to query for posts with either one or another custom field
- Multiple Custom Field Query
- How to update custom field of a posts in a particular category
- How to query posts by month based on date custom field?
- How can I modify my meta_query to work with prices that are stored in the database that contain dollar signs and commas?
- Filter or order based on custom field
- meta_query weird behaviour, static int will work, but not user data
- How to show ACF fields in Gridbuilder custom block
- How to add a “base” filter for all posts visible to visitors on the site?
- WP Admin Dropdown List Filter for custom (ACF) field on custom post type(s)
- Filter posts by their related field’s custom field
- WP meta_query args not working in function
- Query to sort a list by meta key first (if it exists), and show remaining posts without meta key ordered by title
- User Filter Options on Archive Page
- How to add content with a filter when there’s no content in the editor