Hi guys, I am doing a slider with a preview of next and prev items. ACF repeater code:
Would you be so kind and advice me how to start with the last item from the loop please?
Something like this 1,2,3,4 ==> 4,1,2,3
<?php
// check for rows (parent repeater)
if( have_rows('featured_categories') ): ?>
<?php
// loop through rows (parent repeater)
while( have_rows('featured_categories') ): the_row(); ?>
<div class="item"><img src="<?php the_sub_field('category_image'); ?>" /></div>
<?php endwhile;
<?php endif;