Home>Support>Post Loop Widget query issue – category__and

Post Loop Widget query issue – category__and

By alexramsee, 9 years ago. Last reply by Alex S, 9 years ago.
Notice: This thread is over two years old; the information may be outdated. Please consider creating a new thread if you require free support. If you have an active SiteOrigin Premium license, you can email our premium support desk at [email protected].

I wanted to use the Post Loop widget instead writing a new loop because I didn’t have a complex query to run.

I clicked on “Build Posts Query” to access the “Additional” field. I’m simply trying to use the additional field to search for a post with category 1 AND 2, but nothing else.

It doesn’t seem to like what I put in as I keep getting incorrect results.

What is the proper way to use category__and in this case?

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 9 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Alexramsee,

    I would suggest using the taxonomies field to do this instead. It’s a much more user-friendly interface for setting categories. Regardless, the correct query would be, cat=1,2 If you need to exclude a specific category use prepend – before the category id.

  2. 9 years, 4 months ago alexramsee

    Alrighty! Good to know. Thanks for the info.

  3. 9 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Alexramsee,

    No problem. :) Is there anything else I can help you with today?

Replies on this thread are closed. Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More