WordPress.org

Ready to get started?Download WordPress

Forums

Preference Lite
Woocommerce shop page not displaying sidebar (6 posts)

  1. hortensedupin2
    Member
    Posted 4 months ago #

    Hello
    I am having trouble figuring out how to display my themes' (preference lite) templates sidebar on my woocommerce shop page.

    On this page Lookbook: http://bymaryparis.com/?page_id=47, my sidebar is working as this page is NOT a woocommerce page. The page is set to Front Page Template + Right Sidebar using the preference lite theme template.

    However on my boutique page: http://bymaryparis.com/?post_type=product (which is the page Woocommerce created aka Shop), I have it set to Front Page Template + Right Sidebar, just like the Lookbook page but my right sidebar doesn't appear.

    I would like to have widgets for this shop page (boutique) which displays a sidebar of pricing and other shop related settings but can't figure out how to go about doing this with my theme which is preference-lite. (Awesome theme by the way!)

    Any help would be appreciated!

  2. StyledThemes
    Member
    Theme Author

    Posted 4 months ago #

    The Lite version is not setup for WooCommerce, but perhaps this might help:

    For 3rd party Themes

  3. hortensedupin2
    Member
    Posted 4 months ago #

    Hello
    Yes I did follow the instructions on 3rd party Themes (I should of indicated that in my first post).
    In my preference lite file folder I duplicated the page.php and renamed it woocommerce.php as indicated in the 3rd party instructions.

    And here is the code inside my woocommerce.php page:

    <?php
    // Exit if accessed directly
    if ( !defined('ABSPATH')) exit;

    /**
    * Main Page Template
    *
    * @file woocommerce.php duplicated from page.php
    * @package Preference Lite
    * @author Styled Themes
    * @copyright 2013 StyledThemes.com
    * @license license.txt
    * @version Release: 1.0
    * @since available since Release 1.0
    */

    get_header(); ?>

    <!-- Main Content -->
    <div class="container">
    <div class="row">
    <div id="component" class="site-content span12" role="main">

    /* This is what was asked to do in the 3rd party instruction link.*/
    <?php woocommerce_content(); ?>

    </div><!-- #component -->
    </div>
    </div>

    <?php get_footer(); ?>

    I couldn't figure out the use of hooks (as it's for advanced developers, not my case)
    Any other suggestions? If someone out there can explain how to use the hooks, maybe it's a better solution, I would love your help. Just make sure you explain every single detail, from which file to edit to where to add the code and what the code actually does.

    Thanks!

  4. StyledThemes
    Member
    Theme Author

    Posted 4 months ago #

    Actually, I just looked at my theme files. To get a right sidebar, the one you will want is not the page.php file, but the page template "page-right.php"

  5. hortensedupin2
    Member
    Posted 4 months ago #

    OK I think I got it.
    Since I'm trying to learn PHP this is helping a lot.
    One question, how do I find out which php files have referenced files in other pages?
    For example, how do I find out where other $pages, or get_sidebar etc… are on other pages? I hope this is making sense. If not, don't worry, I'll just open all files and compare.

  6. StyledThemes
    Member
    Theme Author

    Posted 4 months ago #

    That is more of a case of looking in the file(s) and seeing what is being listed as a file being called. Long story short, open the files up and see what each has in it.

Reply

You must log in to post.

About this Theme

About this Topic