You can use an custom plugin for your custom fields
function fb_custom_search_where($where) {
// put the custom fields into an array
$customs = array('custom_field1', 'custom_field2', 'custom_field3');
foreach( $customs as $custom ) {
$query .= " OR (";
$query .= "( m.meta_key = '$custom' )";
$query .= " AND ( m.meta_value LIKE '{$n}{$term}{$n}' )";
$query .= ")";
}
$where = " AND ({$query}) AND ($wpdb->posts.post_status="publish") ";
return($where);
}
add_filter( 'posts_where', 'fb_custom_search_where' );
Also you can check the plugin WP Custom Fields Search and you have adhoc an solution.
Related Posts:
- Using meta query (‘meta_query’) with a search query (‘s’)
- Including custom fields in search?
- Add custom fields to search
- Custom search: by post data and post metadata?
- Need small coding with Custom Fields Search
- Search ONLY by meta key / meta values
- Filter results with custom field values and dropdown
- Add custom field (value) to search result (without plugin)
- Is there a way to do multiple ordering on a multiple meta_query?
- searching in custom meta field
- WordPress Search Custom Meta Field Only
- Exclude custom post type from search by custom field value?
- Extend ‘The Events Calendar’ search to include custom fields [closed]
- Include woocommerce custom field value in front-end search result
- Including Database Generated Pages in Site Search [closed]
- Adding Custom Fields to Search
- sort search results by custom fields using dropdown
- Using a checklist to search against metadata
- How do I use wp_query for WordPress search?
- How make a custom search on backend in WordPress without plugin?
- filtering custom post types via meta data drop down
- Advanced search by two criteria – sort by location and date (ascending or descending)
- How do I have WP_Query match posts based on search parameter OR meta fields? (rather than search parameters AND meta fields)?
- Advanced search for meta fields
- Merge Multiple Custom Fields into one New Custom Field for Searching
- How to populate custom field dropdown box based on prior selection?
- Search in Archive Pages by subcategory, tag, custom field and year
- Custom WP_Query for WordPress Search Results with meta_query
- filter custom field values $min $max
- Restrict WordPress Search to Custom Field
- How can you include custom post meta in search without calling each key?
- Include one custom field in search results
- Custom search SQL Query to add custom field in result
- Search Results Page – Displaying Custom Meta Fields
- Custom field Search with Relavanssi
- How to exclude custom fields from search queries?
- How to show content of custom fields in search results?
- Searching with Multiple (Parallel) Criteria on Custom Fields?
- Need to search a custom field (ingredients, one long string per post), but want it to allow phrases/non-exact matches
- Type character in name and make it invisble
- Search & column order by meta value in admin
- search based on custom field
- Very large list of options for BuddyPress profile fields
- searching by keywords in post’s metas or pagination links problem
- Search fails when using the radio buttons
- Admin – Search Events by a custom field
- Search one custom field?
- Create custom query for search?
- Query postmeta values, and return multiple post_titles for common meta value
- Query Custom Fields in Searchform
- Help sorting by Meta Key value
- Custom search with meta fields
- How to display search query as formatted text?
- Search for meta_query does not return any result if combined with title
- Using get_post_meta with new_to_publish
- How to access custom order item meta data from a meta key in WooCommerce?
- Display post_object content using Advanced Custom Fields plugin
- Saving Custom Field in Attachment Window in WordPress 3.5
- Search Custom Post Type with all meta attached?
- Plugin to auto convert custom fields to tag
- Order by Custom Field date not recognized
- How do I read the value of a custom field of the page?
- Displaying additional User Contact Information
- get_post_meta in sitewide tags plugin fails to return value for custom fields
- Making custom field’s ‘Name’ available in the dropdown list by default in a theme?
- WooCommerce conditional required checkout fields [closed]
- Using more than one meta_key in pre_posts_query
- Way To Store Global Meta Values
- How to loop through certain custom field values
- add_action and remove_action if custom field exists
- Store array as single, serialized post meta field or many post meta fields?
- Get an advanced custom field after post publish
- update_post_meta for repeated custom field [closed]
- Categorising search results based on Custom Fields
- Delete custom fields when deleting posts
- Pull custom fields from custom posts within a loop
- Ordering posts by custom field named “date” in backend
- How to display custom fields from a plugin
- Adding “meta” info to WP site PHP function?
- WordPress Media Uploader custom Javascript not working
- List custom queried terms in the edit-tags.php?taxonomy page
- Display meta box dropdown (from custom post type) in the page post type
- how can I show name and value of Custom Fields together?
- Adding simple (one button) Audio player using Custom Fields?
- No result update a custom field using wp_schedule_event
- Display custom widget value in header.php
- Gravity Forms Update post meta from template [closed]
- Display metabox title for custom fields with values
- wpdb function insert doesn’t work
- Adding Custom Metadata to my Archive/Posts page
- User Filter Options on Archive Page
- Login_form add to top of form rather then bottom
- Can’t save meta field value if the title not set
- Get a different meta value with ajax when different elements are clicked
- Why is wp_list_pages altering $post->ID of the page?
- How do you turn a custom field’s value into a permalink for that post?
- How to keep sharing stats after creating 301 redirects?
- Using Hooks. Thematic
- Display posts where date field matches current month?
- Update field name without losing the value