Refining Search Results

This forum is for all Flare issues related to the HTML5, WebHelp, WebHelp Plus, and Adobe Air Targets
Post Reply
pcartee
Propeller Head
Posts: 13
Joined: Tue May 14, 2013 7:28 am
Location: Denver, Colorado
Contact:

Refining Search Results

Post by pcartee »

I'm new to Flare so I'm guessing there is an obvious fix to this problem. When I do a search within HTML help, I get several similar results. The first result in the list operates as expected. The other results present the help topic without the screenshots.

Looking at the results, I see that the other two files are copies of the HTML file stored in two other directories. I included a screenshot to help make this explanation more clear.
You do not have the required permissions to view the files attached to this post.
It's all about the journey, and the journey is Jiujitsu.
LTinker68
Master Propellus Maximus
Posts: 7247
Joined: Thu Feb 16, 2006 9:38 pm

Re: Refining Search Results

Post by LTinker68 »

I'm not quite entirely sure what you're asking/questioning. Are you asking for a way to keep some of the topics from showing up in the search, perhaps the ones in the images folder? If so, then in the Properties screen for each topic, there is an option you can enable that prevents the topic from being searchable.
Image

Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
pcartee
Propeller Head
Posts: 13
Joined: Tue May 14, 2013 7:28 am
Location: Denver, Colorado
Contact:

Re: Refining Search Results

Post by pcartee »

I'm getting multiple search results for each topic; one result from the Content directory, one result from the Image directory, and another result from the Resource directory. The results from the Image and Resource directories display in the help but do not display screenshots. My expectation is that the search results should come from one place within the help file, the Content directory. Since the search results from the Image directory and Resource directory link to copies of the file (topic) that I am looking for but do not display the screen shots, I don't see how they are necessary. Can I prevent Flare form displaying these results? Can I limit my search to just the Content directory?
You do not have the required permissions to view the files attached to this post.
It's all about the journey, and the journey is Jiujitsu.
LTinker68
Master Propellus Maximus
Posts: 7247
Joined: Thu Feb 16, 2006 9:38 pm

Re: Refining Search Results

Post by LTinker68 »

I just did a test and I don't get results from the images folder. I find it odd that it appears to be pointing to an HTML file inside the images folder. Have you double-checked that you don't have a copy of the HTML file in the images folder?

The only other thing I can think of is if you're hosting the help on a web server and are using the advanced search features available in IIS that allow for searching the content in non-HTML files, like Word files, PDFs, etc. If you are, then perhaps it's finding metadata in the images files that match your search terms. For example, if the image filename includes the word "security" or if you have some tags in the file that include the text "security". I don't have that feature enabled on my web server, so I can't test to see if that's what's happening.

If you do have that feature enabled, then I think you need to limit the search scope within IIS, not within Flare.
Image

Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
pcartee
Propeller Head
Posts: 13
Joined: Tue May 14, 2013 7:28 am
Location: Denver, Colorado
Contact:

Re: Refining Search Results

Post by pcartee »

I did have copies of the topic files in the Image and Resource directories. I can only assume that I did something crazy while syncing the project with our source control software. I deleted the files from the Image and Resource directories and rebuilt the help system. All is well.

Is there any way to prevent the file name from appearing at the bottom of the search result?

Thanks for your help.
It's all about the journey, and the journey is Jiujitsu.
LTinker68
Master Propellus Maximus
Posts: 7247
Joined: Thu Feb 16, 2006 9:38 pm

Re: Refining Search Results

Post by LTinker68 »

pcartee wrote:Is there any way to prevent the file name from appearing at the bottom of the search result?
Not from within the Flare GUI, I don't think. You might be able to modify one of the JS files in the output.
Image

Lisa
Eagles may soar, but weasels aren't sucked into jet engines.
Warning! Loose nut behind the keyboard.
pcartee
Propeller Head
Posts: 13
Joined: Tue May 14, 2013 7:28 am
Location: Denver, Colorado
Contact:

Re: Refining Search Results

Post by pcartee »

The option below worked for me. For those who want search results to appear without the file name and path, go the link below.


http://forums.madcapsoftware.com/viewto ... 217#p90190

In case the link doesn't work, the answer is below.

"I did find a way to disable the URLs/file paths in search results for HTML 5 output, but it involves either changing one's output files after building HTML 5 Help (WebHelp 2) OR changing some of the core Flare files. This works in Versions 9 and 9.1.

To change just the output files: Open the Styles.css file in the \Skins\Default\Stylesheets subfolder of your HTML 5 output folder, and change the definition of the .url cite style to remove all of the existing attributes and add the attribute display: none;--once saved, this change entirely suppresses the URLs/file paths in search results.

If you want to suppress the URLs/file paths in search results for all of your HTML 5 outputs without having to change the outputs each time you build them:
1) Save a copy of the Styles.css file in the Flare installation subfolder C:\Program Files (x86)\MadCap Software\MadCap Flare V9\Flare.app\Resources\WebHelp2\Desktop\Skins\Default\Stylesheets. Your installation folder may be in a slightly different location than this.
2) Open the Styles.css file in the Flare installation subfolder C:\Program Files (x86)\MadCap Software\MadCap Flare V9\Flare.app\Resources\WebHelp2\Desktop\Skins\Default\Stylesheets, and change the definition of the .url cite style to remove all of the existing attributes and add the attribute display: none;, and then save the file."
It's all about the journey, and the journey is Jiujitsu.
NorthEast
Master Propellus Maximus
Posts: 6373
Joined: Mon Mar 05, 2007 8:33 am

Re: Refining Search Results

Post by NorthEast »

A much easier way to do this is to set the font color of the search result path to transparent.

Open the skin Styles tab, find the Search Result Path, then set Color to transparent.
pcartee
Propeller Head
Posts: 13
Joined: Tue May 14, 2013 7:28 am
Location: Denver, Colorado
Contact:

Re: Refining Search Results

Post by pcartee »

Dave Lee wrote:A much easier way to do this is to set the font color of the search result path to transparent.

Open the skin Styles tab, find the Search Result Path, then set Color to transparent.
You're correct, but the links would still be there, just not seen. Modifying the .css file removes the links entirely and it's a one time task.

Thanks for the tip.
It's all about the journey, and the journey is Jiujitsu.
NorthEast
Master Propellus Maximus
Posts: 6373
Joined: Mon Mar 05, 2007 8:33 am

Re: Refining Search Results

Post by NorthEast »

pcartee wrote:
Dave Lee wrote:A much easier way to do this is to set the font color of the search result path to transparent.

Open the skin Styles tab, find the Search Result Path, then set Color to transparent.
You're correct, but the links would still be there, just not seen. Modifying the .css file removes the links entirely and it's a one time task.

Thanks for the tip.
You're right that setting display: none will hide the tag rather than just make it invisible; however, if you're really that bothered about that, then remember that it's still present and easily to see in the HTML source by anyone who is inquisitive (e.g. by viewing source, or using developer tools).

I suggested the transparent option because it'll only require a skin change which will be part of your project. I find the problem with making changes to Flare's files, is that (a) everyone has to make the change on every PC that will be used, and they need to remember to do it again after every Flare update, and (b) it will apply to every project you that you build from that PC.
LeeD
Propeller Head
Posts: 11
Joined: Sat Apr 25, 2015 8:25 am

Re: Refining Search Results

Post by LeeD »

Just ran into this topic and implemented it, but I should add that you need to also set the font size to 0 (or something close to that); otherwise the default 13pt size leaves you with this big space between results. :wink:

Hope this helps,
Leon
Post Reply