Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Hide search highlight once in a topic?

Community Expert ,
Oct 28, 2014 Oct 28, 2014

Hi all,

RH version: 11.0.0.179

SSL: Multiscreen HTML5 - Desktop screen profile only

IE version: 9

Is there a built-in widget/thing to add a button to a topic to hide the search highlighting? To be clear, I want the search highlight on, but I want users to be able to turn it off once they have found the topic they need. I've done a little searching in the help and online, so I suspect there isn't, but want to make sure.

If there isn't a built-in function, does anyone know if there is a way to add my own button/javascript? I can read other's code and do a little bit of scripting, but only really basic stuff.

Thanks for your help

371
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Oct 29, 2014 Oct 29, 2014

The widget does the highlighting by reading the url. You will find ?rhsearch=searchstring added to the URL. Once the highlighting is applied, you can remove it with lots of JavaScript. An easier solution may be to create a button to reload the page without the highlight option in the url. A button could do:

document.location = location.protocol + '//' + location.host + location.pathname

Kind regards,

Willam

Translate
LEGEND ,
Oct 29, 2014 Oct 29, 2014

The widget does the highlighting by reading the url. You will find ?rhsearch=searchstring added to the URL. Once the highlighting is applied, you can remove it with lots of JavaScript. An easier solution may be to create a button to reload the page without the highlight option in the url. A button could do:

document.location = location.protocol + '//' + location.host + location.pathname

Kind regards,

Willam

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Oct 29, 2014 Oct 29, 2014
LATEST

Thanks! That looks like it will work a treat.

Now to figure out where I go to get a graphic to harmonise with the website.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp