Hi,
I am building a small workshops feature which I need a little help with.
The way I built it is, I created a Parent Workshops page and I used ACF Field values on the child pages, so that when I publish a workshop, the child pages get a unique workshop link with the dynamic field values on a per workshop basis.
For example, the structure looks something like
Workshops [Parent Page]
-> Workshop 1 [Child]
-> Workshop 2 [Child]
How do I retrieve the ACF unique field values present on the Workshop 1 & Workshop 2 page and use them on the Workshops page.
Any pointers in the right direction will be of immense help.
Thanks.
You need to to a query to get the child pages. You can do this with WP_Query using the post_parent argument or you can do this using a function like https://developer.wordpress.org/reference/functions/get_children/.
Once you do this you loop over the child posts and get the values from those posts.