1. Home
  2. Docs
  3. Related Categories for Wo...
  4. How To
  5. Refining Your Shop Archive Pages with Related Categories

Refining Your Shop Archive Pages with Related Categories


Archives Options

The Related Categories for WooCommerce plugin extends its functionality beyond single product pages, allowing you to showcase related categories on your shop archive pages as well. This can be a valuable tool for guiding customers towards relevant product categories as they browse your store.

Display and Control

  • Display on Archives: Enable this checkbox to activate the “Related Categories” section on your shop archive pages.
  • Limit & Columns: Define the maximum number of related categories to display and how many columns you want them presented in.
  • Hide empty: Choose to hide categories that don’t have any products assigned to them.

Sorting and Ordering

  • Order by: Similar to single product pages, you can define how the related categories are sorted on archive pages. Options include name, ID, slug, menu order, and more.
  • Order: Select ascending (A to Z) or descending (Z to A) order for the chosen sorting criteria.

Relating Categories (Automatic)

This section functions identically to the single product page options, allowing you to automatically determine related.

categories based on

  • Siblings: Display categories that share the same parent category. You can further expand the selection to include grandparents, top-level categories, and grandchildren using the provided options.
  • Parents: Showcase the parent category of the products displayed on the archive page. Include grandparents if applicable.
  • Children: Display all child categories of the products on the archive page. Include grandchildren for a wider selection.
  • Current: Show the category (or categories) that the products currently belong to.

Manual Control (Pro Version)

Upgrading to the Pro version unlocks the ability to manually assign related categories for even greater control:

  • Per category: Set related categories for each individual category directly from the category edit page (Products > Categories > Edit category).
  • Per tag: Assign related categories to specific product tags within the tag edit page (Products > Tags > Edit tag).
  • Per custom taxonomy: For stores utilizing custom taxonomies for product organization, this option allows you to define related categories for each custom taxonomy term. Specify the custom taxonomy slugs separated by commas (e.g., product_brand,product_color).

Positioning and Display Options

  • Position: Choose where to display the “Related Categories” section on your archive pages: before the main content, before the product loop, after the product loop, or after the main content (default after the loop).
  • Position order (i.e. priority): Define the order of the section relative to other elements on the page. A higher number places it lower on the page.
  • Using Shortcodes: The plugin provides a shortcode [alg_wc_related_categories_loop] that you can insert into your theme files to display the “Related Categories” section at any desired location on your archive pages.

Widget Integration

The plugin offers a widget named “Related Categories: Archives” accessible from the “Appearance > Widgets” section. This allows you to easily add the “Related Categories” section to your sidebar or other widgetized areas on your shop archive pages.

Template Customization (Pro Version)

The free version provides a default template for displaying related categories.

The Pro version offers advanced customization options

Template Options

  • Header: Customize the text or HTML that appears before the list of related categories.
  • Footer: Control the text or HTML displayed after the list of related categories.
  • Template type: Choose between “Default” (the plugin’s default template) or “Custom” to create your own layout.
  • Template type: Custom: This option allows you to write custom HTML code using placeholders to define exactly how the related categories are displayed.
  • Template type: Custom: Glue: (Pro Version) This option provides a special way to display related categories with a separator between them, such as a pipe symbol (“|”).

Image Options

  • Image size: Select the size of the category images displayed within the “Related Categories” section. Options include standard WordPress image sizes and custom dimensions.
  • Placeholder image: Choose a default image to display if a category doesn’t have an assigned image. You can also remove the image display entirely.

Advanced Options

  • Visibility: Define when to show the “Related Categories” section:
  • Show for all categories (default).
  • Show only for categories with child categories (categories that have subcategories).
  • Show only for categories with no children (categories that are leaf nodes in your category hierarchy).
  • Reset Settings: Click this button and save changes

Pro Version Link

For access to the advanced customization options mentioned above, you can upgrade to the Pro version of the Related Categories for WooCommerce plugin: https://wpfactory.com/item/related-categories-for-woocommerce/


Related Categories for WooCommerce