Skip to content
Advertisement

Filter WP REST API by taxonomy value (value1, value2, value3 etc…)

I’m trying to filter my Custom post type taxonomy by values, but I haven’t had any success.

I wondered if anyone else knew how to you’d go about doing this, or maybe I’m taking the wrong approach here?

Thanks

Advertisement

Answer

You can pass tax_query in your post query like this:

JavaScript

Also you can filter by taxonomy slug:-

JavaScript

);

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement