Support » Plugin: WooCommerce » wrong sidebar is displayed on shop page

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author James Koster

    (@jameskoster)

    Easiest way to do this would be using our WooSidebars plugin; http://wordpress.org/plugins/woosidebars/

    i tried it but its not working:S It can change every other page but not the shop pages:S

    there are plenty of same issues and no exact solution. most of the time the only suggestion is to use woosidebars which doesnt solve the problem. Another way is supposed to be adding a woocommerce.php file to my existing theme and tell plugin to use desired sidebar. But im not a coder so dont have a single clue how to do that:S .I hope you as a plugin author can find a right solution to it. thanx in advance again:)

    Im using Buddy theme from theme forest. This is my page.php file. I copied it and renamed to woocommerce.php. to what part should i insert <?php woocommerce_content(); ?>

    ??

    <?php get_header(); global $gp_settings; ?>
    
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    
    	<!-- BEGIN CONTENT -->
    
    	<div id="content">
    
    		<!-- BEGIN IMAGE -->
    
    		<?php if(has_post_thumbnail() && $gp_settings['image_wrap'] == "Disable" && $gp_settings['show_image'] == "Show") { ?>
    			<div class="post-thumbnail single-thumbnail">
    				<?php $image = aq_resize(wp_get_attachment_url(get_post_thumbnail_id($post->ID)),  $gp_settings['image_width'], $gp_settings['image_height'], true, true); ?>
    				<?php if(get_option($dirname."_retina") == "0") { $retina = aq_resize(wp_get_attachment_url(get_post_thumbnail_id($post->ID)),  $gp_settings['image_width']*2, $gp_settings['image_height']*2, true, true); } else { $retina = ""; } ?>
    				<img src="<?php echo $image; ?>" data-rel="<?php echo $retina; ?>" style="width: <?php echo $gp_settings['image_width']; ?>px;<?php if($gp_settings['hard_crop'] == "Enable") { ?> height: <?php echo $gp_settings['image_height']; ?>px;<?php } ?>" alt="<?php if(get_post_meta(get_post_thumbnail_id(), '_wp_attachment_image_alt', true)) { echo get_post_meta(get_post_thumbnail_id(), '_wp_attachment_image_alt', true); } else { echo get_the_title(); } ?>" />
    			</div>
    		<?php } ?>
    
    		<!-- END IMAGE -->
    
    		<!-- BEGIN PADDER -->
    
    		<div class="padder<?php if(has_post_thumbnail() && $gp_settings['image_wrap'] == "Disable" && $gp_settings['show_image'] == "Show") { ?> content-post-thumbnail<?php } ?>">
    
    			<!-- BEGIN TITLE -->
    
    			<?php if($gp_settings['title'] == "Show") { ?><h1 class="page-title"><?php the_title(); ?></h1><?php } ?>
    
    			<!-- END TITLE -->
    
    			<!-- BEGIN POST META -->
    
    			<?php if($gp_settings['meta_date'] == "0" OR $gp_settings['meta_author'] == "0" OR $gp_settings['meta_cats'] == "0" OR $gp_settings['meta_comments'] == "0") { ?>
    
    				<div class="post-meta">
    
    					<?php if($gp_settings['meta_author'] == "0") { ?><span><i class="icon-user"></i><a href="<?php echo get_author_posts_url($post->post_author); ?>"><?php the_author_meta('display_name', $post->post_author); ?></a></span><?php } ?>
    
    					<?php if($gp_settings['meta_date'] == "0") { ?><span><i class="icon-calendar"></i><?php the_time(get_option('date_format')); ?></span><?php } ?>
    
    					<?php if($gp_settings['meta_cats'] == "0" && $post->post_type == "post") { ?><span><i class="icon-folder-open"></i><?php the_category(', '); ?></span><?php } ?>
    
    					<?php if($gp_settings['meta_comments'] == "0" && 'open' == $post->comment_status) { ?><span><i class="icon-comments"></i><?php comments_popup_link(__('0', 'gp_lang'), __('1', 'gp_lang'), __('%', 'gp_lang'), 'comments-link', ''); ?></span><?php } ?>
    
    				</div>
    
    			<?php } ?>
    
    			<!-- END POST META -->
    
    			<!-- BEGIN POST CONTENT -->
    
    			<?php if($post->post_content) { ?>	
    
    				<div id="post-content">
    
    					<!-- BEGIN IMAGE -->
    
    					<?php if(has_post_thumbnail() && $gp_settings['image_wrap'] == "Enable" && $gp_settings['show_image'] == "Show") { ?>
    						<div class="post-thumbnail wrap">
    							<?php $image = aq_resize(wp_get_attachment_url(get_post_thumbnail_id($post->ID)),  $gp_settings['image_width'], $gp_settings['image_height'], true, true); ?>
    							<?php if(get_option($dirname."_retina") == "0") { $retina = aq_resize(wp_get_attachment_url(get_post_thumbnail_id($post->ID)),  $gp_settings['image_width']*2, $gp_settings['image_height']*2, true, true); } else { $retina = ""; } ?>
    							<img src="<?php echo $image; ?>" data-rel="<?php echo $retina; ?>" style="width: <?php echo $gp_settings['image_width']; ?>px;<?php if($gp_settings['hard_crop'] == "Enable") { ?> height: <?php echo $gp_settings['image_height']; ?>px;<?php } ?>" alt="<?php if(get_post_meta(get_post_thumbnail_id(), '_wp_attachment_image_alt', true)) { echo get_post_meta(get_post_thumbnail_id(), '_wp_attachment_image_alt', true); } else { echo get_the_title(); } ?>" />
    						</div>
    					<?php } ?>
    
    					<!-- END IMAGE -->
    
    					<?php the_content(__('Read More &raquo;', 'gp_lang')); ?>
    
    				</div>
    
    			<?php } else { ?>
    
    				<?PHP the_content(__('Read More &raquo;', 'gp_lang')); ?>
    
    			<?php } ?>
    
    			<!-- END POST CONTENT -->
    
    			<!-- BEGIN POST NAV -->
    
    			<?php wp_link_pages('before=<div class="clear"></div><div class="wp-pagenavi post-navi">&pagelink=<span>%</span>&after=</div>'); ?>		
    
    			<!-- END POST NAV -->
    
    			<!-- BEGIN AUTHOR INFO PANEL -->
    
    			<?php if($gp_settings['author_info'] == "0") { ?><?php echo do_shortcode('[author]'); ?><?php } ?>
    
    			<!-- END AUTHOR INFO PANEL -->
    
    			<!-- BEGIN COMMENTS -->
    
    			<?php comments_template(); ?>
    
    			<!-- END COMMENTS -->
    
    			<div class="clear"></div>
    
    		</div>
    
    		<!-- END PADDER -->
    
    	</div>
    
    	<!-- END CONTENT -->
    
    <?php endwhile; endif; ?>
    
    <?php get_footer(); ?>

    no help?:(

    Did you get any solution to this?

    esmi

    (@esmi)

    Forum Moderator

    @vrushank: If you require assistance then, as per the Forum Welcome, please post your own topic.

    frustrating. This is an obvious problem, well asked on various posts and no solution to be found. Not everyone is a hard core coder. The main purpose of these forums is so the average user can get solutions. Why do these posts get closed without solutions or the experts say “put that here, then there without clarity? This is a mainstream, obvious question. Please can someone supply an answer clearly and concisely?

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘wrong sidebar is displayed on shop page’ is closed to new replies.