Problems, need help? Have a tip or advice? Post it here.
4 posts Page 1 of 1
Hello,

My site is ready to go online, but I have a little problem I can't solve by myself.

Some blog categories have no entry yet. If I click on a link of an empty one, it shows an empty page, and it's normal.
I'd like to see some words like "This category has no entry yet"

Could you explain how to do, if it is possible in Couch ?

Thanks
Hi,

You can place a cms:no_results tag in the cms:pages block to handle conditions where no pages are fetched -
Code: Select all
<cms:pages ..>
   ...
   
   <cms:no_results>
      <h3>This category has no entry yet</h3>
   </cms:no_results>
</cms:pages>

Hope this helps. Please let us know.

Thanks.
You could also not display the category link if it has no pages:
Code: Select all
<cms:folders>
    <cms:if k_folder_pagecount>
        <a href="<cms:show k_folder_link/>"><cms:show k_folder_title/></a>
    </cms:if>
</cms:folders>
Hello KK, Hello CheesyProof,

I choose the cms:no_results tag. I put it on blog_list.html (in snippet folder) and works like a charm :P

As usually, you are so reactive and efficient ! Thanks a lot
4 posts Page 1 of 1