There are only two channels: 'videos' and 'products'

There are several categories all set by the managers.

Videos are entered as single entries and are given a category or multiple categories, depending on the usage.

Products are entered as a single entry as well. The only field is the playa field where you drag over the related videos for that product.

The page is simple as well. In the product template, I just need to render the {title} of the product for that page/entry. Simple enough.

Then there is a side nav listing the categories of the related/selected videos in the playa field. I only need to show them once, so if there are 30 videos and 3 categories total, it would show something similar to:

  • Category A (14)
  • Category B (12)
  • Category C (4)

An finally in the main page, show the videos per category like:

Category A

VIDEO 1 - VIDEO 2 - VIDEO 3...

Category B

VIDEO 1 - VIDEO 2 - VIDEO 3...

* EDIT *

A little more info...

I run into trouble reading the product entry which has the playa field. The categories are attached to the videos and not the products. I can list out the playa fields in the videos section of the main page, but the side nav is still getting me.

How would I get the list of categories for the videos which are related to the product via playa? (And a count on top of that.)

I could write a query to do this, but I would like to keep it all intact if possible.

  • Please. What the "(14)", "(12)" and "(4)" means? Total of videos per category? Or the category ID?
    – Sobral
    Jul 19, 2013 at 1:08
  • Total count of entries with that category related to that product entry.
    – W3bGuy
    Jul 19, 2013 at 14:33

1 Answer 1


I ended up changing direction and making two category groups. One for Products and one for Sections. The can enter a list of products in the category Products and use Sections for the 'category' segments. This way I can just use "EE2 Child Categories" plugin by Nico to sort and filter as needed throughout the page.

To remedy the category url in the title, I just wrap everything in a query like so:

{exp:query sql="SELECT cat_id, parent_id FROM exp_categories WHERE cat_url_title='{segment_2}'"}

This way I can use the ID's and render the names and links for everything after.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.