Home › Forums › ACF PRO › Add filter on the relationship field inside a group › Reply To: Add filter on the relationship field inside a group
Hi, my filter works if I put the name of the relationship field.
My problem is that I have many group fields with relationship fields inside all with the name “items” so the filter applies to all these fields.
I want to apply the filter only to the group field with the name “link_scope_pages” and in particular to its relation subfield with the name “items”.
From various topics such as wp_query I tried to use the group name “_” name of the subfield relationship “link_scope_pages_items” but this doesn’t work.
Here is my problem.
At the moment I solved it with the key name of the relationship subfield (it seems to be unique), but I wanted to know if there was a solution with the names or even putting conditions inside the filter.
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!
Sorry for the issues with ACF's API SSL certificate this morning. We've resolved it and your activations and downloads should be back to normal again. Thanks! ^LG— Advanced Custom Fields (@wp_acf) November 2, 2022
© 2022 Advanced Custom Fields.