Are you a GenerateCustomer?

Do you have an active GP Premium or GenerateBlocks Pro license key?

Create a GenerateSupport account for GeneratePress and GenerateBlocks support in one dedicated place.

Create an account
Already have a GenerateSupport account? Login

Just browsing?

Feel free to browse the forums. Support for our free versions is provided on WordPress.org (GeneratePress, GenerateBlocks).

Want to become a premium user? Learn more below.

dynamic category filter for blog

  • Hi GeneretePress-Team,
    I have a blog archive page on my website that displays all posts in a four-column layout. I’d like to add a category filter to this page. There is a content template element to style the appearance of the archive page.

    Above the posts, I want to display one button for each existing category (ideally generated dynamically, so that a button is automatically created when a new category is added).
    When one of the buttons is clicked, only posts assigned to that category should be shown.

    I found a similar filter function on the “Dispatch” demo site. Unfortunately, I can’t install the demo from the site library to see how it was implemented there (it’s not available in the library).
    https://gpsites.co/dispatch/category/time-saving/

    Thanks a lot!

  • Hi there,

    The categories on the dispatch template is NOT dynamic, it’s just a secondary menu, the menu is created manually.

    You are using WP category list block, it is a better option.

  • Thank you for your reply.
    So using the category list block and styling with additional css is the way to go? Like it is in the “read” demo site?

  • So using the category list block and styling with additional css is the way to go?

    Yes, it is 🙂 I made the Geek template, the category list was added in this way, it’s the only way to make it dynamic.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.