if($all_vendors->have_posts() ) { ?>
<div class="row">
<?php $i=0; ?>
<?php while ($all_vendors->have_posts()) { ?>
<div class="col-lg-4 d-flex align-items-stretch vendor-col">
<?php $all_vendors->the_post(); ?>
<div class="card">
<?php $image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->post_id), 'full' ); ?>
<a class="stretched-link" href="<?php echo get_post_permalink()?>"><img style="padding-bottom:30px;" class="card-img-top img-fluid" src="<?php echo $image[0]; ?>" alt="Card image cap" ></a>
<div class="card-body">
<p style="text-align:center;" class="card-text"><a class="stretched-link" href="<?php echo get_post_permalink()?>"><?php if(get_field('other_details')){the_field('other_details');}?></a></p>
</div>
</div>
</div>
<?php $i++; if ($i % 3 == 0) {echo '</div><div class="row">';}
} //endwhile ?>
<?php wp_reset_query(); ?>
<?php } //end if have posts ?>
</div> <!-- end row outside of loop