Home › Forums › General Issues › User with apostrophe in name not found › Reply To: User with apostrophe in name not found
ACF uses the WP function get_users() with it’s defaults. By default WP only looks in ID, user_ligin, user_email, user_url and user_nicename.
To look in other fields you’d need to alter the query parameters. This can be done using the hook acf/fields/user/query
. I don’t think this one is documented here.
This is from the ACF code
// filters
$args = apply_filters("acf/fields/user/query", $args, $field, $options['post_id']);
$args = apply_filters("acf/fields/user/query/name={$field['_name']}", $args, $field, $options['post_id']);
$args = apply_filters("acf/fields/user/query/key={$field['key']}", $args, $field, $options['post_id']);
I think you’ll need to supply custom ‘search_columns’, but I’m not 100% sure
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.