Wp E-commerce Conditional sidebar (2 posts)

  1. surfsup74
    Posted 3 years ago #

    I'm setting up wp e-commerce for the first time so need a little help. I would like to only display wp ecommerce content in the sidebar when i am within the shop area of the site (ie not when I'm on a blog post or other page).

    what i need is something like:

    if (is in the shop area() { get_sidebar('special-wp-specific') {else { get_sidebar();}

    seems simple enough - however I can't find any docs on how this is achieved.



  2. jodamo5
    Posted 3 years ago #

    Hi Dan. I'm just in the process of setting it up too, but I've found a really easy way to do it. Install a plugin called "Widget Logic". Then you get a logic field added to each widget. It uses the wordpress conditional tags to easily allow you to choose when the shopping cart shows up.

    There's helpful explanations on the Widget Logic information pages too:

    I wanted to hide the shopping cart on the checkout page. (Seemed silly having it appear on that page). My checkout page is page 5, so I just used this one line and it worked:
    (which means, "display when the page does not equal page 5")

Topic Closed

This topic has been closed to new replies.

About this Topic