# Einblendung Badge anhand der Kategorie ein- und ausblenden

**URL:** <https://forum.shopware.com/t/einblendung-badge-anhand-der-kategorie-ein-und-ausblenden/93525>\
**Category:** Shopware 5\
**Created:** [17. März 2022 um 12:42 UTC](https://forum.shopware.com/t/einblendung-badge-anhand-der-kategorie-ein-und-ausblenden/93525 "2022-03-17T12:42:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lightbox](https://avatars.discourse-cdn.com/v4/letter/l/c6cbf5/32.png) [@lightbox](https://forum.shopware.com/u/lightbox)\
**Post date:** [17. März 2022 um 12:42 UTC](https://forum.shopware.com/t/einblendung-badge-anhand-der-kategorie-ein-und-ausblenden/93525/1 "2022-03-17T12:42:46Z")

</div>

Ich möchte gerne das bestimmte Badges im Listing und auf der Artikeldetailsseite nur dann angezeigt werden, wenn die Artikel sich in der Kategorie „Ersatzteile \> Leuchtmittel“ befinden.

{extends file=„parent:/frontend/listing/product-box/product-actions.tpl“}  
{namespace name=„frontend/listing/box\_article“}

{block name=‚frontend\_listing\_box\_article\_actions\_content‘}

{$smarty.block.parent}

{\* EEC LABEL \*}  
{if $sCategory==„Ersatzteile \> Leuchtmittel“}  
{block name=‚frontend\_listing\_eec\_label‘}  
{s name=„EEC\_DE“}{/s}  
{/block}  
{/if}

{/block}

So sind sie im Listing überall verschwunden auf der Artikeldetailsseite sind sie noch überall vorhanden. Kann mir jemand helfen?
