Home › Forums › Add-ons › Flexible Content Field › get_field returns null for repeatable field in flexible content field › Reply To: get_field returns null for repeatable field in flexible content field
PHP7 is running on the server and the field is a repeater. I’m trying to get a count of the repeater items with $count = count( get_sub_field( 'testimonials_module' ) );
. I’ve even tried this with get_the_ID()
as the second param to force this but that did not work either. A dump of get_the_ID()
is pulling the correct ID by the way.
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.