If you are creating a custom theme, the default-sidebar for Woocommerce is the standard.  Custom sidebar must be created to accomplish this as most ecommerce sites will require an individual and unique sidebar to be created to accommodate the customer experience and ultimately drive results.

Two easy steps to accomplish this.

Step 1:

Modify your sidebar.php file in your theme.

Add

if ( function_exists( ‘is_woocommerce’ ) && is_woocommerce() ) { get_sidebar( ‘woocommerce’ ); }

else { get_sidebar( ‘primary’ ); } prior to ‘primary’ sidebar.

Variations include

if ( function_exists( ‘is_woocommerce’ ) && is_woocommerce() ) { dynamic_sidebar( ‘woocommerce’ ); } else {get_sidebar ( ‘default-sidebar’ )

Step 2:

Register your dynamic sidebar in your functions.php file located in your theme.

Add: register_sidebar(array( ‘name’ => ‘Woocommerce’,

‘id’ => ‘woocommerce’,

‘before_widget’ => ‘<aside id=”%1$s”>’,

‘after_widget’ => ‘</aside>’,

‘before_title’ => ‘<h3>’,

‘after_title’ => ‘<span></span></h3>’, ));

 

That’s it. Custom sidebar on WooCommerce.  Not much documentation anywhere in this GEM.

We encourage you to contact bLogix today at (844)-4-BLOGIX and schedule an initial consultation and speak with experienced consultant to discuss your business requirements.  Results matter.

Salesforce Award Winning CRM, Learn More

  Producing results since 2006 for clients nationwide and throughout South Carolina including Spartanburg, Greenville, Anderson, Rock Hill, Charleston, Columbia, Greenwood county.  North Carolina including Charlotte, Mecklenburg county, Gastonia, Research Triangle Park (RTP), Raleigh, Winston-Salem, Asheville.  Scottsdale & Phoenix Arizona, Atlanta, Georgia, Washington D.C. metro Virginia and Southern California.