WordPress.org

Ready to get started?Download WordPress

Forums

Problem with my query_posts request (2 posts)

  1. skapiso
    Member
    Posted 6 years ago #

    Hi everyone,

    I want to display my news except the news of the category 21. So i read in the codex that i've to do something like this:

    query_posts($query_string . "&cat=-21&order=ASC");

    It works for the category but the order doesn't work. The request bug only if I exclude a category. If i Do :

    query_posts($query_string . "&cat=21&order=ASC");

    the order works.

    Someone have an explication or a solution?

    thanks a lot.

  2. uxte
    Member
    Posted 5 years ago #

    Hi, I have the same problem.

    Did anyone come up with a solution for this? I know that the problem is by excluding the category with the "-" signal.

Topic Closed

This topic has been closed to new replies.

About this Topic