I am using the shortcode 'wpv-view' to display post category terms. Currently it is :
[wpv-view name="ads-filter-category-view" orderby="id" order="asc"]
I want to be able to select certain categories using the shortcode. Is this possible?
Regards,
David
Hi David, you need to use a filter inside the view itself.
Here's a screenshot of mine.
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Hello. Thank you for contacting the Toolset support.
Well - as I understand, you only want to display selected terms with the view? could you please be more specific with your requirement.
Hi Minesh,
"Well - as I understand, you only want to display selected terms with the view? could you please be more specific with your requirement."
That is the requirement. But using the shortcode rather than a filter inside the view as I want a client to be able to add categories to the shortcode. Is this possible?
Regards,
David
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Well - You should add query filter to your taxonomy view filter by shortcode attribute.
Please check following image:
hidden link
And add taxonomy view as:
[wpv-view name="ads-filter-category-view" orderby="id" order="asc" terms="125,55,88"]
Where:
- Adjust "terms" attribute with your term Ids as you required.
Hi Minesh,
Is it possible to use term slugs or names or does it have to be IDs?
Regards,
David
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Well - you can see all available options when you add term query filter:
See the screenshot:
hidden link
In your case, the suggested way is possible.