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.

How to exclude parent entries in {exp:weblog:category_archive}

March 12, 2008 7:45pm

Subscribe [0]
  • #1 / Mar 12, 2008 7:45pm

    Peter Sommerfeld

    86 posts

    For a master archive I want to exclude the entries of parent categories because in case of parent/children the entries are shown twice: once in the parent category and one time more in the children category.

    Here is may code:

    {exp:weblog:category_archive weblog="{embed:blog}" style="nested" show_empty="no" show_future_entries="yes"}
    
    {categories}
    <div>{title-de}</div>
    {/categories}
    
    {entry_titles}
    <a href="http://{entry_id_path={embed:blog}/index/}">{title}</a>
    {/entry_titles}
    
    {/exp:weblog:category_archive}

    Within the {entry_titles} seems to be no normal way to access the category itself.
    So how to do it?

    Peter

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

ExpressionEngine News!

#eecms, #events, #releases