• Resolved Moses001

    (@moses001)


    I am really excited about this plugin. It is very simple so shouldn’t slow a website down.

    I read prior question in forum but am confused.

    I want to display Woocommerce Categories and SubCategories (parents with their children) and products for the subcategories.

    While looking at the documentation I have tried several things, but nothing displays. So I am back to the bare bones example you gave earlier in the forum.

    I am not understanding how and what I need to include in the for/each loop.

    Here is my latest code which results in nothing displaying.

    ‘[for each-product_cat term=”this,that,other” orderby=”slug”]
    Category: [each name]
    [field title]
    [if children]
    [-for each=”child”]
    Subcategory: [-each]
    [field title]
    [field thumbnail]
    [field image-caption]
    [/-for]
    [else]
    No subcategory
    [/if]
    [/for]’

    This plugin is really great. I know I am doing something wrong.

    Thanks for providing some direction.

Viewing 1 replies (of 1 total)
  • Thread Starter Moses001

    (@moses001)

    Here is the code I used to display category and subcategories. I guess the only way to display subcategories is to use [each link]

    ‘[for each=”product_cat” parents=”true”]
    <b>Pumps By: [each link]</b>
    Click Links Below To See Specific Pumps)
    [-for each=”child”]
    [each link]
    [/-for]
    [/for]’

    The above code worked for me.

Viewing 1 replies (of 1 total)
  • The topic ‘Custom Content Shortcode Plugin Category Subcategory Display’ is closed to new replies.