0

I want to display an entry's category, but only from a specific category group.

{exp:channel:entries channel="paintings" limit="10"}
{title}
{categories group_id="42"}{category_name}{/categories}
{/exp:channel:entries}

If I just use: {categories}{category_name}{/categories} I get all categories but I only want categories display if they are in group 42. If they have nothing in group 42 I want nothing to display

2

{categories show_group="42"}{category_name}{/categories}

| improve this answer | |
  • Based on the docs, that SHOULD output only the categories within the group with ID 42 that the current entry is assigned to, as you described. – Jean St-Amand Jun 1 '13 at 18:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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