Support

Account

Home Forums Add-ons Repeater Field Repeater field automatically populating rows

Solving

Repeater field automatically populating rows

  • I have an image repeater on a site. Without adding anything to the field, the site is automatically adding 2 rows and will not allow me to delete them. There is no requirement or minimum number so I’m stuck here.

  • What happens when you try to delete them?

    Did you build the site?

  • No it was built by someone else but I’m hosting it now. The fields delete when I hit the remove button but when I hit update they come right back.

  • You need to search the code on the site. More than likely there is a filter that is automatically adding the rows when the repeater value is loaded. It could be on the hooks acf/load_value. acf/load_field or acf/prepare_field. There might be others. This is the only way that rows could be automatically added when the repeater field settings does not have a minimum number of rows. I would search the theme for all ACF hooks to see what I could find, but I can’t really tell you exactly what to search for.

    The previous developer must have had a reason for doing this. I would also be looking at the code to figure out why. Removing them might cause errors depending on how it is coded.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.