ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Need help correlating category to content

February 09, 2011 5:12pm

Subscribe [1]
  • #1 / Feb 09, 2011 5:12pm

    brianfrick

    8 posts

    I’m trying to dynamically display a particular snipped based on the category in which my content article resides.  One channel [types] contains the template where I list all content entries [articles] by category.  I use this code to dynamically include the proper snippet, and it works great:

    <h1>Life@Home: our original articles about {exp:channel:category_heading}{if category_name == "PD"}PD{if:elseif category_name == "CHHD" OR category_name == "NHHD" OR category_name == "DHHD"}HHD{/if}{/exp:channel:category_heading}</h1>

    The link to the content is as follows:

    {title_permalink='article/life_at_home'}

    As you can see, this directs me to another channel [article] and template [life_at_home].  I would like to know how to determine the category of the content within this new channel and template so that I can dynamically display the same proper snippet, as above?

    I’m stumped.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases