<?php if (have_rows('items')) $ir = 0; : while ( have_rows('items') ) : the_row(); ?>
<?php if ( $ir % 2 == 0 ) : ?>
<div class="col">
<div class="item">
<?php the_sub_field('item-info'); ?>
</div>
<?php else : ?>
<div class="item">
<?php the_sub_field('item-info'); ?>
</div>
</div>
<?php endif; ?>
<?php $ir++; endwhile; endif; ?>
jQuery(function($){
$('.box_input input').on('change', function(){
var thisId = $(this).attr('id');
$('.labelbox label').removeClass('checked');
$('.labelbox label').each(function(){
if( $(this).attr('for') == thisId ) {
$(this).addClass('checked');
}
});
});
});