Support » Fixing WordPress » Changing The Loop to display only 1 post from certain categories w/ date sort

  • I would like to create a version of the Loop to use on my site that does the following things:

    • Shows only 1 post from certain categories
    • Shows exactly 10 posts
    • Posts are sorted by date

    I can’t figure out how to do it with all the 3 conditions. I know that if I use multiple loops with some If/else statements the first condition can be fulfilled, but it results in either less than 10 posts being displayed, or the posts not being sorted correctly.

    I really have no idea how to do this, so any help would be greatly appreciated.

  • The topic ‘Changing The Loop to display only 1 post from certain categories w/ date sort’ is closed to new replies.