Forums › Forums › Search & Filter Pro › results separate by custom post types
Tagged: custom post types, results, terms
- This topic has 11 replies, 2 voices, and was last updated 5 years, 10 months ago by Anonymous.
-
Anonymous(Private) January 8, 2019 at 11:51 am #198288
Hi everyone!
I’m building a search and filter with diferent custom post types. As I’ve seen I can’t use query options and I’m stuck trying to separate the results in groups having each group the custom post type name.
Example. I’ve jobs, courses and trips. You can filter all of them by countries. The results of selecting one country will give jobs, courses and trips.
How can I separate them on blocks? Like, jobs block with its title, courses block with its title, etc,…
Thank you in advance
Appreciate your time!
Trevor(Private) January 8, 2019 at 12:35 pm #198301On the Posts tab, you can sort results by Post Meta (Custom fields) but not taxonomies (because a post can have multiple taxonomy terms, and these are stored as an array by WordPress, whereas sorting requires a single value), and also sort by Post Type.
Here is an example:
https://www.screencast.com/t/H57cgjKX
The addition of separators or titles depends on the PHP template you are using, but is not in itself built in to Search & Filter.
Trevor(Private) January 8, 2019 at 12:51 pm #198310If you did not mean to sort them by the methods I showed, then I do not understand what you mean to sort by terms? Could you give me more detail to help me understand?
As to adding a title etc, that would be something either you or a freelance coder you might hire would need to do.
Anonymous(Private) January 8, 2019 at 1:08 pm #198318Yes exactly.
I’m trying to sort the results by terms having each sorted group a title (the term). All what I’ve found to acomplish this is using queries but is not after paying the pro version that I saw that the plugin doesn’t work with queries.
Thank you
-
AuthorPosts