1. CYBER MONDAY SALE Get Divi.Help Pro Membership @ $99 / lifetime & instantly gain access to all our Divi.Help Pro Membership perks.LEARN MORE
Dismiss Notice
NEW Divi.Help Pro Carousel AI Toolkit - Magically turn your Divi design into carousel, simply by using our online toolkit. No plugins needed.Try our carousel AI toolkit
BEST Divi Block - A revolutionary drag & drop tool to easily mix & match 960+ premade blocks (Light & Dark) to kick start your Divi site design. Special module designs are included as well. Also newly added AI generator & color.
Learn More About Divi BlockFree Version ~ 340+ Free Blocks

How can I show a list of WooCommerce categories on a page

Discussion in 'Free Divi Community Forum' started by Duvy, Jan 22, 2020.

  1. Duvy

    Duvy New Member

    Hi All,
    I would like to show on a webstore a list of all category product on a page not the wp category. How to do that ?
    I like the way DIVI layouts are shown, you select a category in the left panel and it show you all relevant layout. This is a brillant way but not sure I can realise that logic on my store page ;-)

    Thanks in advance for any clue or to point me in the right direction.

    Yvon

    PS : all modules and plugins are up to date, this is a brand new installation
     
    1. PRO MEMBER PERKS Divi.Help One-Page Layouts - Beautifully crafted one-page Divi layouts just for you:View All Layouts
  2. Duvy

    Duvy New Member

    See this print screen
    upload_2020-1-23_10-29-28.png
     
  3. Duvy

    Duvy New Member

    Can you give me any clue to realise that kind of module with DIVI and WOOCommerce.

    Thanks a lot,
    Yvon
     
    1. PRO MEMBER PERKS Divi Ultimate Archive Plugin - Replace the default archive "Older Entries" with beautiful pagination:Learn More
  4. Divi.Help

    Divi.Help Administrator
    Staff Member

    For your sidebar, just add a Product Categories widget. You need to add it in WP Admin > Appearance > Widgets
     
  5. mav1creator

    mav1creator New Member

    You can create new page with divi builder and add a code section with [product_categories] content
     
    Pat likes this.
    1. PRO MEMBER PERKS Divi Ultimate Child Theme - Tons of premade layouts & section designs + functionalities for your Divi site:Learn More
  6. MostOftenBaffled

    MostOftenBaffled New Member

    When you use the woo shortcode, it will give you limted formatting options. Here is how to implement an image overlay and the magnifying glass icon, as you would your shop page (this is an unbridged example; you can change colours, icons, etc; to suit your UI. Concatenate the functions.php code .. I've just done it like this for clarity. Use your own class names, etc.

    Put this in your child themes Functions php. (wrap the category shortcode in a class by injecting HTML tags)

    add_action( 'woocommerce_before_subcategory_title', function( $category ){ echo '<div class="ab_container">';},8,1);
    add_action( 'woocommerce_before_subcategory_title', function( $category ){echo '<div class="ab_overlay">';},10,1);
    add_action( 'woocommerce_before_subcategory_title', function( $category ){echo '<div class="ab_icon">T</div>';},11,1);
    add_action( 'woocommerce_before_subcategory_title', function( $category ){echo '</div></div>';},12,1);

    Style in your child theme's style.css

    .ab_container{
    position:relative;
    }
    .ab_container:hover .ab_overlay{
    opacity: 1;
    }

    .ab_icon {
    font-family: 'ETmodules';
    color:#ea9010;
    font-size: 32px;
    position: absolute;
    top: 50%;
    left: 50%;
    -webkit-transform: translate(-50%, -50%);
    -ms-transform: translate(-50%, -50%);
    transform: translate(-50%, -50%);
    text-align: center;
    }

    .ab_overlay{
    position:absolute;
    top:0%;
    left:0%;
    height: 100%;
    width: 100%;
    opacity: 0;
    transition: .5s ease;
    background-color:rgba(35,47,63,0.46);
    }


    upload_2021-10-16_20-9-24.png
     

    Attached Files:

    Pat likes this.
  7. Ethan Milton

    Ethan Milton New Member

    1. Click on Appearance > Customize.
    2. Then go to WooCommerce > Product Catalog.
    3. Select “Show categories” from Shop Page Display.
    4. Click on Save Changes
     
    claudiotouchard likes this.
    1. PRO MEMBER PERKS Divi Block Pro - Premade team carousel design for your Divi site without using any plugins:View Demo
  8. MostOftenBaffled

    MostOftenBaffled New Member

    The Divi shop module over-rides the woocommerce settings. To list categories only, the shortcode has to be used.
     
  9. Pat

    Pat New Member

    That means you can use the shortcode for Shop page, but iot won't work for any parent category parent.
    It is unable to list only child categories of a prent category ?!
     
    1. PRO MEMBER PERKS Divi.Help Pro Layout Packs - Agency Divi layout pack featuring unique comment design on single blog post page:View Demo
  10. Pat

    Pat New Member

    Actually that means with Divi, we can not customize Category Pages via Theme Builder on a web site having parent and child categories, right?!
    Even with the shortcode, we are unable to show only child categories if they exist, or only products inside Theme Builder.
    that is a big issue!
     
    Hardy Krüger likes this.
  11. DaveSherbet

    DaveSherbet New Member

    I agree it's a big issue
     
    Pat likes this.
    1. PRO MEMBER PERKS Divi.Help Pro Layout Packs - Beautifully crafted Divi layout packs for you to kick start your Divi sites:View Demo