I don’t know whether the problem described below is related to Gutenberg, ACF or Elementor. So, I’m reporting it to all sides.
I have created CPTs to which some custom fields are attached via ACF. The authors create custom posts, edit them in Gutenberg (they are not allowed to use Elementor) and fill in the custom fields. Each of these CPTs is handled by a corresponding Elementor model. This model dynamically retrieves the contents of the custom fields and display them.
While the posts are in draft mode in Gutenberg, previewing in Gutenberg is working fine. As soon as the post has been published, previewing in Gutenberg is no longer working correctly : all the elements displaying the custom field contents are empty in the preview. Switching back to draft mode makes the problem disappear.
However, the post is always displayed correctly in any case for the site visitors. Only the previewing doesn’t work.
I don’t understand where the problem could be.
Any idea ?
Thanks in advance.
I’m having this same trouble in the classic editor. I tried to implement the fix listed here and it didn’t work.
When I make a new custom post I can preview and see the ACF data, but once I hit publish, any changes I make to ACF fields are not visible.
No real solution found BUT I have identified the source of the problem : Elementor.
If you go to Elementor and edit the model corresponding to the post that you are editing in Gutenberg, you’ll probably see that the preview settings of Elementor have been reset to a post that has nothing to do with the model that you are editing. This happens all the time since a while. So, if you update the previewing settings so that the Elementor editor uses your target post for previewing, the previewing in Gutenberg will now work correctly.
Not satisfactory since our editors and authors cannot adjust the Elementor preview settings so that Elementor uses the post that is currently edited in Gutenberg but at least we kbow where the problem is. Not an ACF problem.
You must be logged in to reply to this topic.
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!
© 2021 Advanced Custom Fields. Subscribe