Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <tr>
- <?php
- // The Query
- $args = array(
- 'post_type' => array( 'pratos_dos_dia', 'grelhados_do_dia' ),
- 'posts_per_page' => 12
- );
- $the_query = new WP_Query( $args );
- $counter = 0;
- // The Loop
- while ( $the_query->have_posts() ) {
- $the_query->the_post(); ?>
- <td><h2><?php the_title(); ?></h2><br><h5><?php the_field('acompanhamento'); ?><h5></td>
- <td><h5><?php the_field('meia_dose'); ?>€</h5></td>
- <td><h5><?php the_field('dose'); ?>€</h5></td>
- <?php
- if ($counter % 2 != 0 ){
- echo '</tr><tr>';
- }
- $counter++;
- }
- /* Restore original Post Data */
- wp_reset_postdata();
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement