WordPress.org

Ready to get started?Download WordPress

Forums

How to create a multiple category posts archive page (2 posts)

  1. mbzo2006
    Member
    Posted 3 years ago #

    I would like to know how to create a single archive page that sorts posts from a bunch of categories and displays the posts in order (most recent first).

    Something like:
    Title of the most recent post that happens to be in category B
    Excerpt (Read More)

    Title of recent post that happens to be in category A
    Excerpt (Read More)

    Title of a less recent post in category A
    Excerpt (Read More)

    Title of an older post in category C
    Excerpt (Read More)

    etc.

    Then there is pagination ... page 2,3,4 etc of same above

  2. Kisa-chan
    Member
    Posted 2 years ago #

    I think this could work

    http://codex.wordpress.org/Pages#A_Page_of_Posts

    you can change the $cat so it would be an array of the IDs of the categories you want to list, then you only have to change

    'category__in' => $cat,

    instead of

    'category__in' => array($cat),

    Hope it helps =)

Topic Closed

This topic has been closed to new replies.

About this Topic