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.

Listing Number of Entries in a Category

January 06, 2008 6:35pm

Subscribe [3]
  • #1 / Jan 06, 2008 6:35pm

    Nevermore

    14 posts

    So, I was wondering if there was a way to list the number of entries in a category.  I looked in the documentation and saw how to list the entry titles in a category, but all I really want to do is list the number of entries in the category.  Is that possible or should I just keep track by hand?  (;

    (I’m doing Blog 365 and I wanted to keep track on the side how many posts had actually gone up for the year…)

  • #2 / Jan 06, 2008 8:10pm

    PXLated

    1800 posts

    Is this what you are looking for… Wiki ... Category Count?

  • #3 / Jan 06, 2008 8:39pm

    Nevermore

    14 posts

    IT looks like - though I just want to do one SPECIFIC category, not all of them.  Any thoughts on how to modify that code for that?

    (THanks for this!  I feel dumb now (; )

  • #4 / Jan 06, 2008 10:46pm

    PXLated

    1800 posts

    I’m not that good with queries, I always have to play around with them, but I would think the second example would work by giving it the specific category id you want…untested and the cat id may need enclosing quotes…

    FROM exp_category_posts WHERE exp_category_posts.cat_id = 1 “}

    Actually, you could strip down the first example for a specific cat id also.

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

ExpressionEngine News!

#eecms, #events, #releases