Groups within flexible content fields

Hello,

How do we display group fields nested in a flexible content field? I am able to display using the other fields like text, textarea etc. But no luck with the groups. Has anyone tested this before?

Thanks,
Kendell

Hi Kendell, thank you for the question.

The “group” field type is not supported yet - I’ve made a note to add this soon, including when it’s inside a flexible content field. Will let you know when it’s ready.

Hello, ACF Group field type is now supported in version 2.0.6.

It’s accessed with the Loop tag and acf_group attribute.

<Loop acf_group=field_name>
  <Field title />
</Loop>
1 Like

Many thanks for your quick reply on this @eliot!

I had the chance to give it a try with a group and it works as expected. But can it handle nested groups?

I have a group inside of another group, but it doesn’t seem to work. Is it possible?

I did some tests with nested groups, including inside flexible content, and confirmed that they’re working. For example:

<Loop acf_group=parent_group>

  Parent: <Field text />

  <Loop acf_group=child_group>

    Child: <Field text />

  </Loop>
</Loop>

Could you see what might be different in your case? I’ll try to re-create the issue on my side to solve it.

Thank you @eliot.

I thought the structure for child groups would’ve been:
<Loop acf_group=parent_group_child_group_another_child_group>

But it is clear now. I’m looking into it, will let you know if I end up with any issues.

1 Like