Get a fast, conversion-focused WooCommerce theme in 2024. Switch to Shoptimizer.

Home Documentation Shoptimizer Shop and Categories Display products and subcategories on separate rows on listings pages

Display products and subcategories on separate rows on listings pages

When displaying products and subcategories on the shop or listings pages, both products and subcategories can appear on the same row. This is a bit strange, as subcategories and products are different and are normally separated.

These solutions will hopefully enable you to display subcategories and products independently from each other.

Approach One (CSS only)

You will need to add the following CSS to Appearance > Customize > Additional CSS, or within the styles.css file of your child theme.

The solution is designed for a 4-column grid on the shop and listings pages. If you are using a 3-column grid, you will need to change all references to 4 in the code below to 3.

Approach Two (PHP)

This is an alternative approach which uses just PHP. The PHP should be added via the Code Snippets plugin, or the functions.php file within a child theme.

Because we’re actually moving the markup this approach could be considered more robust.

$50
Off

Do you want a whopping $50 off Shoptimizer for WooCommerce?

Click the button below to get Shoptimizer for only $49. (Regular price: $99).
This is a special launch offer for today only.
Get it before it is gone!