Home › Forums › Add-ons › Repeater Field › Generate XML using sub_fields recursively › Reply To: Generate XML using sub_fields recursively
Hi @bart-gopnik
The numbers you saw is the index of the repeater row. It’s there to group the rows to avoid confusion while processing it (imagine you have multiple fields in a single row).
If you want to get rid the index numbers and you want to have numbers as the subfield name, then you need another method to do that. Unfortunately, this is more related to PHP instead of ACF. Kindly get in touch with PHP community for further support.
Also, yes, It seems I missed the exclamation point. The correct code is !is_numeric($k)
. I’m sorry about that.
I hope this makes sense 🙂
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.