1

Here's how to isolate only your chosen categories. This works off the premise that if a related category is a parent of one of the other related categories, it is not a category you chose. {% set relatedCategories = entry.myCategoryField.with(['parent']).all() %} {% set parentCategories = relatedCategories | map(c => c.parent) %} {% set chosenCategories = ...


Only top voted, non community-wiki answers of a minimum length are eligible