Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #11678

    I need to move the Product Ordering drop-down menu from the shop header to the shop sidebar. Ideally this would be as simple as adding a Woocommerce product ordering widget to my shop sidebar but alas, this widget doesn’t seem to exist.

    So, into the code we go…

    It appears that the product ordering drop down is currently being generated in the shop header by the function woocommerce_catalog_ordering() as called from within the function avia_woocommerce_advanced_title().

    I have successfully removed this from the shop header.

    Now the question is, how to add this to the shop sidebar?

    It appears that the shop sidebar is being generated in /config-woocommerce/config.php/ here…


    function avia_woocommerce_after_main_content()
    global $avia_config;
    $avia_config[‘currently_viewing’] = “shop”;

    //reset all previous queries

    //get the sidebar

    echo “</div>”; // end container
    echo “</div>”; // end tempate-shop content

    I tried adding a call to woocommerce_catalog_ordering() immediate after the call to get_sidebar() but this didn’t have any effect.

    Any direction here would be greatly appreciated. Thank you.


    I haven’t tested this but imho you can simply add this function to sidebar.php. Add the code somewhere before following code:

    // single shop sidebars
    if ($avia_config['currently_viewing'] == 'shop_single' && dynamic_sidebar('Single Product Pages') ) : $default_sidebar = false; endif;

Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘Move Product Ordering from Shop Header to Shop Sidebar’ is closed to new replies.