Grid with loop breaking in wordpress! Using Foundation6 as a framework

0

Good afternoon, I've been having a lot of problems when doing a grid with a loop, like the posts of a grid blog, follow an illustration image:

Does anyone know what to do for the grid not to break? Here is the code:

<!-- the loop -->           
        <?php while ( $custom_query->have_posts() ) : $custom_query->the_post(); ?>

          <article class="loop large-6 columns text-center">
            <div class="img-post"><a href="<?php the_permalink();?>"><?php the_post_thumbnail('medium-large', array( 'alt' => get_the_title(), 'title' => get_the_title() ) ); ?></a></div><br>
            <div class="titulo-post medium-11 medium-centered"><h2><strong><a href="<?php the_permalink();?>"><?php the_title(); ?></a></strong></h2></div>             
            <div class="content medium-10 medium-centered text-justify">
              <!--?php the_excerpt(); ?-->
              <a href="<?php the_permalink();?>"><div class="text-center"><button class="button">LEIA MAIS</button></a></div><br><br><br>
          </article>

        <?php endwhile; ?>
        <!-- end of the loop -->
    
asked by anonymous 16.03.2017 / 19:23

1 answer

0

You have a few ways to do this. Using a grid plugin type esse

If the grid always has the same size, you can set a fixed height. In the code you put you miss a div with the class 'row' to make the lines. It is also important as you can see here

    
10.05.2017 / 17:43