This problem is driving me a bit nuts. I’m working on a site where I select an area first and if an area category has been chosen it shows a list of all types of activities. This works but only as long as I select an area where I have entries.
My most basic problem is, why doesn’t the {if not_category_request} nor the {if category_request} show anything when I have a URL with a category ID that doesn’t have any entries? If I have no category ID in the URL or a category ID that contains entries everything works as expected.
There must be some relationship behind the scenes that I’m not aware of.
Thanks for the help,
Timon
<div id="navigation">
{exp:weblog:entries limit="1"}
{if not_category_request}
{exp:weblog:categories show_empty="yes" style="nested" category_group="3"} {!-- Category Group "Area" --}
<a href="http://{path=">{category_name}</a>
no request {!-- output for testing purposes --}
{/exp:weblog:categories}
{/if}
{if category_request}
{exp:weblog:categories show_empty="yes" style="nested" category_group="2"} {!-- Category Group "Type" --}
<a href="http://{site_url}{site_index}/{segment_1}/{segment_2}/{segment_3}/tag/{category_name}">{category_name}</a>
{/exp:weblog:categories}
category requested {!-- output for testing purposes --}
{exp:subcategories}
<strong><a href="http://{path=">{category_name}</a></strong>
{/exp:subcategories}
{/if}
{/exp:weblog:entries}
</div>Mod Edit: Moved to the How To forum.