Skip to content

Instantly share code, notes, and snippets.

@AaronRutley
Created May 15, 2017 11:44
Show Gist options
  • Save AaronRutley/bf1bb8f862e2afc4c2012b42b9437b1d to your computer and use it in GitHub Desktop.
Save AaronRutley/bf1bb8f862e2afc4c2012b42b9437b1d to your computer and use it in GitHub Desktop.
<?php
if (have_rows('my_repeater_field')) {
$mycounter = 0;
while (have_rows('my_repeater_field')) {
the_row();
$mycounter++;
echo $mycounter;
}
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment