Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- * Template Name: Full-width Page Template, No Sidebar
- *
- * Description: Twenty Twelve loves the no-sidebar look as much as
- * you do. Use this page template to remove the sidebar from any page.
- *
- * Tip: to remove the sidebar from all posts and pages simply remove
- * any active widgets from the Main Sidebar area, and the sidebar will
- * disappear everywhere.
- *
- * @package WordPress
- * @subpackage Twenty_Twelve
- * @since Twenty Twelve 1.0
- */
- get_header(); ?>
- <div id="primary" class="site-content">
- <div id="content" role="main">
- <?php
- $args = array( 'post_type' => 'product', 'posts_per_page' => 10, 'category__and' => array( 20, 61, 74, 28 ), 'orderby' => 'date' );
- $loop = new WP_Query( $args );
- while ( $loop->have_posts() ) : $loop->the_post(); global $product; ?>
- <?php echo do_shortcode('[product id="'.$loop->post->ID.'"]') ?>
- <?php endwhile; ?>
- <?php wp_reset_query(); ?>
- </div><!-- #content -->
- </div><!-- #primary -->
- <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement