3

I have a client that wants their Solspace Calendar Events to show up in the global site search results (along with entries from other sections)

My first thought was to query the entries and calendar events separately, merge the result sets together, and then paginate them. Basically this: Merge Craft entries and Venti events in search results

Unfortunately that doesn't seem to work. Is there any way to accomplish this?

2
  • were you able to find a resolution for this? I'm in a similar boat, where the client wants everything from Craft and Solspace Calendar in the global search results. Commented Jan 12, 2018 at 15:50
  • @thescottallen Nope. It's easy enough to merge the results together, and output them, but it doesn't work with pagination. You could implement pagination manually, but it's a lot of screwing around. Additionally I couldn't find a way to merge based on relevance score, So, events either appear at the start or the end of the results. In the end I added a another loop on the first page of results which search for events, it shows up to three events, and if there are any more, it renders a link to a separate event search page. Commented Jan 14, 2018 at 22:37

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.