Page 1 of 1

CGBlog: Hide categories from browscat

Posted: Wed Aug 19, 2015 4:04 pm
by cpansewicz
I would like to be able to exclude a category from the browsecategory template. Below is the code from this post: http://forum.cmsmadesimple.org/viewtopi ... =7&t=63400

The code works great, but I can't figure out how to include the child categories in this code.

<ul>
{foreach from=$categories item='one'}
{if $one.name != 'foo'}
<li class="{$one.name}"><a href="{$one.url}" title="{$one.name}">{$one.name}</a>&nbsp;({$one.count})</li>
{/if}
{/foreach}
</ul>

SOLVED: CGBlog: Hide categories from browscat

Posted: Thu Aug 20, 2015 2:33 pm
by cpansewicz
I did figure this out on my own. I just used the sample browse category template provided, and added to the line {if $rec >0}

AND $cid=1 (the category I wanted to show)