Very close! We just need a $ sign in front of that key variable, and it works!
'key' => $flex_field_name,
Thanks much! Mean it!
Dalton:
I posted a question about your answer in a more current thread: https://support.advancedcustomfields.com/forums/topic/performance-of-backend-super-slow/#post-56310
Even with correct front-end code, this issue contributes to problems in the back-end.
I would love to see if you have more input.
I’m seeing major dashboard performance issue in a site that was built about 5 years ago. It relies heavily on repeaters for page modules / layouts. Over time, modules have come and gone – both globally and within individual pages. To make matters worse, the site’s marketing team has duplicated pages to build new ones. (So old meta is carried forward again and again – even though not used.)
Over time, a tremendous amount of unused meta data has been stored for lots of pages. Front-end performance is fine, but the dashboard has slowed to a crawl.
I’ve seen the following statement posted on a few threads that sort of addresses this issue:
“I’m going back to several old threads to report the fix for this problem. As of ACF Pro 5.5.8, flexible fields clean up after themselves when they’re deleted and no longer leave orphan data in the postmeta table.” ~
(https://support.advancedcustomfields.com/forums/topic/data-still-in-db-any-solution/)
Does this mean that as of v5.5.8, ACF started deleted data from fields that themselves have been removed within a page’s dashboard? If so, does this also apply to repeaters (not just flexible content)?
I need to be able to offer my client a solution. It would be good to say that the problem will not be ongoing, and we can try to clean up old instances via the database. It would also be helpful to find guidance on how to convert repeater fields to flexible content fields.
I’ve tried several approaches… no love. Looking forward to the solution!
I don’t have an acf-json folder in my theme. I ended up going another route to get the website done, but definitely want to keep ACF as my primary tool moving forward. So I’m very interested in seeing how this resolves itself.
I’m having the same issue – in the non-pro version.
I’m having the same problem – even with all other plugins deleted.
I’m having the same issue, I believe. I’ve added custom fields to a home page using the default front-page.php as a template. I can add data to the fields, but the data won’t save.
I set the page to a named page template, and the problem was solved.
Update: I removed the named page template, removed the front-page template and reset to default. I could save new data and display with the now default page.php. But here’s where it gets weird… for the heck of it, I put the front-page template back in the direct, re-entered and saved new data… and it worked.
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 Cookie Policy. If you continue to use this site, you consent to our use of cookies.