amitabhaghosh197
7/7/2014 - 8:46 PM

woocommerce

woocommerce

<?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 stepup
 */
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
get_header('shop'); ?>

  <?php  
  
   // Theme option Home Settings -> Banner Image Checked Yes/ Not 
  
  ?>
  

   
    
  <?php $options = get_option('redux_demo');   ?>
<?php

  
 if(isset($options['opt-checkbox-ba'] ) && ($options['opt-checkbox-ba'] ) == '1') {?>

  
     <?php    get_template_part('templates/header-banner');    ?>
  

      <?php } else {?>
      <div class="container">
              <div class="row-fluid">
                       <div class="no-header-bg span12">
                       
                              <div class="no-header-bg-wrapper">
                              
                                                <div class="span8">
                                                     <h1> <?php  woocommerce_page_title(); ?> </h1>
                                                 </div> <!--------/span8------------------>
                                                 
                                                 
                                         <div class="span4">
                                           <div class="breadcrumb-position pull-right">
                                          <?php the_breadcrumb();   ?>
                                          </div>
                                         </div> <!-----/span4--------------------->
                                 </div><!-----/no-header-bg-wrapper------------------------------>
                         </div> <!---------/no-header-bg------------------>
                 </div> <!-----/row-fluid-------------------------->                         
      
      </div><!----------/container-------------------->
      
      <?php  } ?>


   <?php
   
    // All Other Contents
   
   ?>
  
	<div id="primary" class="content-area">
		
            <div class="container other-page">
               <div class="row-fluid">
                 <div class="span8">
                  <div class="page-wrapper">
                  <?php
		/**
		 * woocommerce_before_main_content hook
		 *
		 * @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content)
		 * @hooked woocommerce_breadcrumb - 20
		 */
		do_action( 'woocommerce_before_main_content' );
	?>
    
		<?php if ( apply_filters( 'woocommerce_show_page_title', true ) ) : ?>

			<h1 class="page-title"><?php woocommerce_page_title(); ?></h1>

		<?php endif; ?>

		<?php do_action( 'woocommerce_archive_description' ); ?>
   <?php if ( have_posts() ) : ?>
    <div class="woocommerce-before-shop">
			<?php
				/**
				 * woocommerce_before_shop_loop hook
				 *
				 * @hooked woocommerce_result_count - 20
				 * @hooked woocommerce_catalog_ordering - 30
				 */
				do_action( 'woocommerce_before_shop_loop' );
			?>
 </div><!----------/woocommerce-before-shop---------------------->
 

    <?php woocommerce_product_loop_start(); ?>

				<?php woocommerce_product_subcategories(); ?>
                
			<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
            <?php 
			if(is_shop() || is_product_category()):?>
            
            
            <?php  wc_get_template_part( 'content', 'product' ); ?>
            <?php  elseif(is_product()) :?>
			
                <?php wc_get_template_part( 'content', 'single-product' ); ?>
				
    <?php endif; ?>
		  
			<?php endwhile; // end of the loop. ?>
           <?php endif; ?>
            
            <?php woocommerce_product_loop_end(); ?>
            
            	<?php
				/**
				 * woocommerce_after_shop_loop hook
				 *
				 * @hooked woocommerce_pagination - 10
				 */
				do_action( 'woocommerce_after_shop_loop' );
			?>
            
            <?php elseif ( ! woocommerce_product_subcategories( array( 'before' => woocommerce_product_loop_start( false ), 'after' => woocommerce_product_loop_end( false ) ) ) ) : ?>

			<?php wc_get_template( 'loop/no-products-found.php' ); ?>


		<?php endif; ?>
         
            <?php
		/**
		 * woocommerce_after_main_content hook
		 *
		 * @hooked woocommerce_output_content_wrapper_end - 10 (outputs closing divs for the content)
		 */
		do_action( 'woocommerce_after_main_content' );
	?>
     
            </div> <!-----/page-wrapper------------------------->
                   </div><!--------/span8---------------->
                      
                       <div class="span4 border-left">
                       
                       <?php get_sidebar('shop'); ?>
                       </div> <!----/span4 /border-left------------------->
	               </div><!-----------/row-fluid---------------->
        </div><!----------/container /other-page-------------->
	</div><!-- #primary -->

<div class="clearfix"></div>
<?php get_footer('shop'); ?>