Support

Account

Home Forums Add-ons Repeater Field Repeater field saying no rows found Reply To: Repeater field saying no rows found

  • Tried that way and still no luck. It is still saying there are no rows found when there are rows.

    <?php if( have_rows('layout_section') ): ?>
    
        <?php while ( have_rows('layout_section') ) : ?>
    
            <?php the_row(); ?>
    
            <?php if (get_sub_field('layout_section_type') == "feat_section") { ?>
    
                <p>Featured Section</p>
    
            <?php } elseif ( get_sub_field('layout_section_type') == "feat2" ) { ?>
    
                <p>Featured Section 2</p>
    
            <?php } elseif ( get_sub_field('layout_section_type') == "feat3" ) { ?>
    
                <p>Featured Section 3</p>
    
            <?php } else { ?>
    
                <p>Normal Section</p>
    
            <?php } ?>
    
        <?php endwhile; ?>
    
    <?php
    else :
        echo '<p>No Rows Found</p>';
        // no rows found
    endif;
    ?>

    Here are the config pages. First one of the repeater field itself

    The layout type options

    Just using it for text at the moment for debugging