Home › Forums › Front-end Issues › Image not attached to post on save acf form › Reply To: Image not attached to post on save acf form
You need to write a filter so that when the post is saved the featured image is set for the post. Grab the image info from the acf field and create a filter for ‘acf/save_post’ action. The function should have something like this:
add_post_meta($post_id, ‘_thumbnail_id’, $value);
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.