This support ticket is created hace 7 años, 2 meses. There's a good chance that you are reading advice that it now obsolete.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
I am building a site in the educational field and have multiple post types. E.g. Posts, Pages, Courses, Speakers, People, Brochures, FAQs, Venues, Testimonials.
I am trying to create a global custom search where a single search box will bring back results from all of these post types. At preset a search on mutiple post types gives jumbled up results.
I would like the results to be grouped into their post type.
Therefore the results will look like:
<h2>Courses</h2>
Course 1
Course 2
Course 3
[AJAX Pagination if required]
So to me this would work like a Taxonomy view, with sub views showing the contents of that taxonomy, but obviously with post type instead of taxonomy.
I can't see a way to do this other than to add a taxonomy that applies to all post types, and setting the values to the same as the post type - not a very elegant solution and it would rely on users always adding the correct taxonomy to every post - something users can't be relied upon to do.
To display the result in groups for each post type using parametric search you should create separate views for your each CPT and set filters accordingly.
For example:
Posts:
[wpv-view name="posts view"]
Pages:
[wpv-view name="pages view"]
Courses:
[wpv-view name="courses view"]
Speakers:
[wpv-view name="speakers view"] and so on.