Skip Navigation

[Resolved] highlight search term in results

This support ticket is created 5 years, 10 months ago. 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.

This topic contains 2 replies, has 2 voices.

Last updated by Ido Angel 5 years, 10 months ago.

Author
Posts
#1182521

hey,

the theme's default is to highlight a search term in the results, like here:

hidden link

but when i search with toolset, the highlighting stops:

hidden link

i tried applying this custom search as a search results archive, to replace the theme's search - but that didn't work.
is there a way to get this working, as the theme already has this function?
if not - is there a plugin i can dload somewhere - and how would i go about initiating it in my custom search?

thx!

#1182781

This is not something that 's possible out of the box with Toolset.
If you wish to see this natively in Toolset I'd suggest to write in here:

For now, you might apply custom solutions:
https://toolset.com/forums/topic/highlight-search-terms-in-results/
The solution there uses a 3rd party plugin to which you can pass the Views URL Query parameters, this seems a very neat solution, see:
https://toolset.com/forums/topic/highlight-search-terms-in-results/#post-416123

There was a bit of troubleshooting that is above the scope of support in Toolset for that ticket. However, I think with all the information there you should be able to set this up without hassle.
I think this is the plugin they used there:
hidden link

As for adapting the Theme's behaviour, you would need on what JS functions it hooks the feature, then add that to Views. Probably you will need to alter that feature's code as well to listen to any other URL params than native default ?s.
That is why I would suggest a new, more holistic solution like in the linked ticket.

#1182830

Thanks Beda! This actually worked!!!