Support » Plugin: W4 Post List » Group by Post Category

  • Resolved ChWebP


    Great plugin! Is it possible to group by post category? (My list is alphabetical. It would be great to group by each letter. It would be even better to have each group collapsed showing just the letter, and you click to expand to see all the posts that start with that letter.)

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Shazzad Hossain Khan


    It should be fairly easy to create a Category + Post list , where category are sorted alphabetically. To do this –

    1. Go to List creation page.
    2. Select “List Type” = Category + Post
    3. Click on “Terms” Tab
    4. Set “Taxonomy” to “Category”, “Orderby” to “Name”, Order to “ASC”, “Items per page” to -1
    5. Click on “Posts” Tab
    6. Set “Post Type” to “Post”, “Post Status” to “Publish”, “Orderby” to “Title”, “Order” to “ASC”.
    7. Click on “Template” Tab. Use this there –

      <li><a href="[term_link]" class="my_cat_link" data-toggle="#cpl_[term_id]">[term_name]</a>
      <ol class="my_post_list" id="cpl_[term_id]">
        <li><a href="[post_permalink]">[post_title]</a></li>

    8. Click on “Style” Tab. Use this there –

          $( $(this).data('toggle') ).toggle();
          return false;

    9. Save the list. Copy the Shortcode and use it on Page, Post or Widget Area.

    Thanks for using the plugin.

    Thanks for your fast and helpful support!
    Can this be done also for grouping by post name?

    Plugin Author Shazzad Hossain Khan


    Please post a review here 🙂

    And there’s no option for Group By Post name, and logically how could that be, is there multiple post with same name ?

    So, the idea would be…



    Where Ace, Apple, etc are the post titles. They would be grouped by the first letter in the post title, so the long list is visually easy to navigate.

    Plugin Author Shazzad Hossain Khan


    Well, this is can be achieved.

    1. Install this plugin – Custom Post Type UI
    2. Register a Custom Taxonomy for Post (name it “Alphabet”)
    3. Insert Some Terms (A,B,C,D) for that taxonomy.
    4. Then Chose appropriate taxonomy for each of the post. There’s a bulk edit function which could be useful.
    5. Then create a new Post List – Category + Post
    6. On “Terms” tab – Select the newly created taxonomy (whatever you named it, maybe “Alphabet”)
    7. Then follow the steps i posted earlier. (
    8. On “Template” tab, remove the line –
    <a href="[term_link]" class="my_cat_link" data-toggle="#cpl_[term_id]">[term_name]</a> – (this is because you wont need to display the taxonomies)
    9. “Style” tab could be empty, as there’s no show/hide mechanism.

    ** Taxonomy == Group (ex: Continent)
    ** Terms == Group Element (ex: Africa)

    Cheers 🙂

    Thanks! Where is step 3 completed? I can’t find anything labeled “Terms” in the new plugin “Edit Custom Post Type or Taxonomy” section.

    Plugin Author Shazzad Hossain Khan


    I am not sure what they have named, Probably “Custom Taxonomies” or “CPT”. And your won’t find terms there. Lets assume you have created the CPT named “Alphabet”. Then, you would see it under the Posts menu, below “Categories”, “Tags”.

    Hope it helps.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Group by Post Category’ is closed to new replies.