Home › Forums › General Issues › Search in the relationship field with text › Reply To: Search in the relationship field with text
I fixed it now!
I changed the 5 lines to this:
add_filter('acf/update_value/type=relationship' ...
.
I also saw you used get_the_title()
, which is a better idea than what I was doing, which was get_post()
.
Now it works, and the values I need are saved in the database.
Also, since I have 5 different fields per post, I use the $field['_name']
plus a string to get seperate a meta_key
per relationship field per post.
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.