Repeater Showing Only Every Other Row
-
Official support site is having issues (503/timeout) so I though I’d post here.
I’m using the repeater successfully and recently had an issue where every other row is displaying (not all).
Here’s my code:
<?php if( have_rows('lma_dates') ): while ( have_rows('lma_dates') ) : the_row(); ?> <?php $res=the_row(); $time = $res['date']; if ($time >= date('m/d/Y')){ ?> <div class="lma-day"> <div class="lma-date"><?php the_sub_field('date'); ?></div> <div class="lma-rate"><?php the_sub_field('rate'); ?></div> <div class="lma-details"><?php the_sub_field('details'); ?></div> </div> <?php } ?> <?php endwhile; ?> <?php else : ?> <?php endif; ?>
I run a check to hide rows that include a date earlier than today. The problem seems to have arose after we implemented this check (although not sure if it’s the cause)
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Repeater Showing Only Every Other Row’ is closed to new replies.