Hi!
We are using a repeater on our front page to display banners. Well. That’s the idea anyway. I can just get one banner to displayed. If I try to add another banner the first one disappears.
Any ideas why?
Cheers,
Jes
Here’s the code:
<?php
$frontpage_id = get_option( ‘page_on_front’ );
if ( have_rows(‘banners’, $frontpage_id) ): ?>
<?php while ( have_rows(‘banners’, $frontpage_id) ) : the_row();
$image = get_sub_field(‘banner_bild’,$frontpage_id);
$url = get_sub_field(‘banner_url’,$frontpage_id);
$id = get_sub_field(‘banner_id’,$frontpage_id);
if ( !empty($image) ): ?>
” target=”_blank”>
” alt=”<?php echo $image[‘alt’]; ?>” id=”<?= $id ?>” />
<?php endif;
endwhile; ?>
<?php endif;
?>