Support » Plugin: WooCommerce » Unable to implement Woocommerce in custom build theme

  • Resolved MainGateMedia

    (@maingatemedia)


    Hi there,

    I’m trying to implement Woocommerce into our custom build theme by using woocommerce_content()to replace <?php if ( have_posts() ).But i don’t have that line of code, instead this is showing in my file:

    <?php
    /**
     * The template for displaying all pages
     *
     * This is the template that displays all pages by default.
     * Please note that this is the WordPress construct of pages
     * and that other 'pages' on your WordPress site will use a
     * different template.
     *
     * @package WordPress
     * @subpackage Twenty_Twelve
     * @since Twenty Twelve 1.0
     */
    
    get_header(); ?>
    
    <main>
    
     <section class="section-content section-page">
    
    	<div class="container">
    	      <div class="row">
    
    		<div class="col-sm-7">
    		  <?php while (have_posts()) : the_post(); ?>
    		    <?php get_template_part('content', 'page'); ?>
    		    <?php //comments_template( '', true );  ?>
    		  <?php endwhile; // end of the loop.  ?>
    		</div>
    	        <div class="col-sm-4 col-sm-offset-1">
    	         <section>
    	           <?php get_sidebar(); ?>
    	         </section>
                    </div>
    
                   </div>
                </div>
    
     </section>
    
    <?php get_footer(); ?>

    When i replace (have_posts()) : the_post(); and then save it as woocommerce.php it gives me errors.

    Can anybody help me?

    https://wordpress.org/plugins/woocommerce/

Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Unable to implement Woocommerce in custom build theme’ is closed to new replies.