<?php global $post; $args = array( 'posts_per_page' => 6, 'post_type'=> 'service', 'orderby' => 'menu_order', 'order' => 'ASC' ); $myposts = get_posts( $args ); foreach( $myposts as $post ) : setup_postdata($post); ?> <?php $service_link= get_post_meta($post->ID, 'service_link', true); ?> <div class="col-sm-6 col-md-4"> <div class="services-tiem"> <?php the_post_thumbnail('thumbnail', array( 'class' => 'hvr-buzz-out' )); ?> <h3><a href="<?php echo $service_link; ?>"><?php the_title(); ?></a></h3> <p><?php the_content(); ?></p> </div> </div> <?php endforeach; wp_reset_query(); ?>
Leave a Reply