Created
June 27, 2017 12:28
-
-
Save davoraltman/cedbdb166fe71bf120510ccad91d418b to your computer and use it in GitHub Desktop.
Make custom meta field searchable
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function my_wpjm_meta_key_dm() { | |
global $wpdb, $job_manager_keyword; | |
$searchable_meta_keys[] = '_my_meta_field'; | |
return $searchable_meta_keys; | |
} | |
add_filter('job_listing_searchable_meta_keys', 'my_wpjm_meta_key_dm'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment