If Entry is related to Category-A, then print xyz I have succussfully been able to list entries within the 'brandx' category slug, but I can't figure out a way to print specific content only if the current 'product' listing is related to the 'brandx' category.

I have tried quite a few things and have come up empty, so I feel like I'm either missing something basic, or there's a trick I can't find in the docs or here.

{% paginate craft.entries.section('shopDetails').level(1).limit(24) as postsOnPage %} 
      {% for product in postsOnPage %}
           …
            &lt;h5&gt;
              {% set cat = craft.categories.slug('brandx').first() %}
              {% set catGroup = craft.entries.relatedTo( cat ) %}
              {% if product {# is within the catGroup #}  %}
              Brand X
              {% endif %}
              {{ product.title }}
            &lt;/h5&gt;
{% endpaginate %}
All you need to do is this in the product for Loop

{% if product.category.first.slug == 'brandx' %}
    Brand X
{% endif %}


Or Shorthand 

{{ product.category.first.slug == 'brandx' ? 'Brand X' }}  


Not tested but thats the gist of it.

--Edited