Home Forums Add-ons Repeater Field Basic table display of repeater fields Reply To: Basic table display of repeater fields

  • sorry I copied the wrong code, that code above didn’t mention image anywhere…

    <?php if(get_field('vessels')):?>
                <div class="vessel">
    			<?php while(has_sub_field('vessels')): ?>
                <img />" />
                <?php the_sub_field('name'); ?>
                <?php the_sub_field('type'); ?>
                <?php the_sub_field('year'); ?>
                <?php the_sub_field('lxb'); ?>
                <?php the_sub_field('pull'); ?>
                <?php the_sub_field('passengers'); ?>
                <?php the_sub_field('spec'); ?>
                <?php endwhile; ?>
    <?php endif; ?>
    i can't get the image line to display its above the sub field called name:
    <img src="<code><?php $image = get_sub_field('image'); echo $image['url']; ?></code>" />
    only ignore the <code></code>