[Plugin: wp e-Commerce] trouble with thematic sidebar on single product page (3 posts)

  1. fizzyfozzy
    Posted 4 years ago #

    I'm using WP e-Commerce to set up a shop but having trouble getting my sidebar to display on the single product pages.
    I'm using a Thematic Child theme.
    I've copied over the shop template files and had a look at the single product template but this only contains everthing within the 'single_product_page_container' div. I need to pull in the sidebar below the contaciner div...
    What do I need to edit?

  2. fizzyfozzy
    Posted 4 years ago #

    Ok, I've found a work around. Based on this post: http://getshopped.org/forums/topic/sidebar-not-showing-in-the-2011-theme/

    I replaced:

    // calling the standard sidebar

    in page.php in my child theme with:

    if (is_active_sidebar('primary-aside')) {
    	echo thematic_before_widget_area('primary-aside');
    	echo thematic_after_widget_area('primary-aside');

    That did the trick.

  3. TrickleUp
    Posted 4 years ago #

    I had the same problem using a thematic theme child theme. The problem I found that was causing this was that the wpsc_all_products_on_page (in wpsc-includes/theme.functions.php) action that wpsc adds to the template_redirect hook exits at the end of running, therefore disabling all template_redirect actions that are scheduled to run after this action.

    Among the actions that don't run are thematic_connect_functions() on priority 10, which is why the sidebars don't show.

    I solved it by doing this (removing the action):

    function stop_wp_ecommerce_from_messing_up_wordpress() {
    	remove_action('template_redirect', 'wpsc_all_products_on_page');
    add_action('template_redirect', 'stop_wp_ecommerce_from_messing_up_wordpress', 1);

    I'm not sure whether this messes up something else, I have yet to test it thoroughly. The exit() call seems like bad design.

Topic Closed

This topic has been closed to new replies.

About this Topic