I created an ACF repeater field on my options page but I’m unable to retrieve the value using get_field()
. How do I retrieve the repeater value?
I created an ACF repeater field on my options page but I’m unable to retrieve the value using get_field()
. How do I retrieve the repeater value?
3
Answers
According to ACF - Get values from an options page, you need to add
'option'
as the second parameter inget_field()
.See this example:
Replace repeater with the name of your field and inside the_sub_field() with what you have included.