Search result filter system

This forum is for all Flare issues related to the HTML5, WebHelp, WebHelp Plus, and Adobe Air Targets
Post Reply
john-hetherington
Jr. Propeller Head
Posts: 2
Joined: Thu Oct 19, 2017 8:31 am

Search result filter system

Post by john-hetherington »

Hi all,

My team have just purchased Flare and we have started building our new guide site. One thing we're very keen to do is have a filter that appears after the search rather than use the built in pre-search drop-down functionality. I've attached a rough image of what we're trying to achieve. When a user searches a term on the landing page, it will show the results for the entire project. Then using check-boxes the user will be able to filter the results based on product, user type, and/ or media type.

I know this isn't achievable out of the box but I was hoping that someone here may have tried something similar and could give us some advice. We're already looking into hacking around the concepts feature. Any feedback would be appreciated!

Thanks
You do not have the required permissions to view the files attached to this post.
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Search result filter system

Post by NorthEast »

If you look at the search results page URL in the address bar, you'll see it includes the search term and search filter; e.g.

Code: Select all

SearchResults.htm?q=term&f=filter
So you could include a form with a radio button for each filter, then reload the search results page with the appropriate filter in the URL.


Another way might be to use jQuery to copy (clone) or move (appendTo) the filter menu from the from search bar, and display that somewhere else it in the results page.
That might be a quick and dirty way to do it - or it might not work at all!


However, you cannot select multiple search filters, as you have in your screenshot - you can select one filter OR another, not one filter AND another.
roboHAL
Sr. Propeller Head
Posts: 254
Joined: Mon Dec 31, 2012 9:57 am

Re: Search result filter system

Post by roboHAL »

Hi john-Hetherington.

I'm assuming you are using the latest version of Flare, 2017 r3 and that your output is HTML5. While I could be misunderstanding your inquiry, I'd like to point out that the built in Search Filter Set feature would allow you to filter search results before or after search results are displayed. And, you could assign "Concepts" to topics with the Product, User Type and Media Type combinations that are possible. Point is, I believe the functionality you desire *is* achievable "out of the box"

Best. :)
IPRO_JB
Propeller Head
Posts: 13
Joined: Mon Jan 29, 2018 1:31 pm

Re: Search result filter system

Post by IPRO_JB »

John,

Were you ever able to figure this one out? We're endeavoring to allow users to select multiple products and search across all of the topics associated with those products, using search filters. However, it appears that search filter sets only allow a single filter set to be selected (drop-down list not checkboxes). It sounds like what you were trying to do is what we are trying to do. Any luck so far?

Julie
JRtechw
Propeller Head
Posts: 68
Joined: Thu Oct 05, 2017 8:08 pm

Re: Search result filter system

Post by JRtechw »

Having a bit of a look at this myself. (In HTML5 top nav.)

While I'm not interested in boolean filter sets just yet, I do want to create a mini-search bar that is set to use a different search filter to the global one that is applied to the 'global' search bar in the hero banner. The mini-search bar would search the subset of articles in the left-side-column menu proxy.

You can manually construct a 'Flare site search URL' with search terms and filters, as Dave demonstrates below. Entering a constructed URL in the URL bar has the same effect as entering search text into the search bar, selecting a filter, and pressing OK or clicking the search button. So, in theory, this is how it should work:

1. Enable the global project search filter in the target. (This works whether you actually show the filter option in search or hide it; you just have to publish with the filter enabled.)
2. Insert mini-search proxy in a master page.
3. Write a js snippet that takes entered search terms and constructs a 'Flare search URL' dedicated to whichever filter you want to employ, like: 'http://knowledgebase.net/au/product/sea ... <setfilter>.
4. 'Hijack' the event that detects the mini-search input has been triggered, to redirect the current page to your 'search URL'. Flare will happily hoover up the search URL and spit out a search results page as if you used the search bar and filter as normal.

[With a bit of work, you could also use this as a 'search the results' refine search, by converting your search results into a filter on the fly. ]

I'm scouring through the search .js files to work out number 4 at the moment. If I get it working, I'll report back.
lcarver
Propeller Head
Posts: 17
Joined: Mon May 21, 2018 8:20 am

Re: Search result filter system

Post by lcarver »

This is very helpful, thank you to everyone who commented here!

JRtechw, the steps you outlined make sense to me, but I'm just starting to learn a bit of JS in order to build my own search filter buttons (I'm not a programmer... yet :lol: ). I want users to be able to see which filter they're choosing, rather than the dropdown list disappearing after a filter is selected. I'm wondering, did you ever get #4 working? If so, would you be willing to share more details of it?

Cheers,
Lexi
JRtechw
Propeller Head
Posts: 68
Joined: Thu Oct 05, 2017 8:08 pm

Re: Search result filter system

Post by JRtechw »

Hi Lexi,

Unfortunately, I have been sidetracked by a project to integrate Flare's CleanHTML output into MS Dynamics using the Dynamics Web API. I'd almost forgotten about this, but it would still be a cool thing to do. Might look at this in Q1 2019.

Sorry I didn't have happier news!

Cheers,

JR
chrisj
Propeller Head
Posts: 87
Joined: Thu Jun 26, 2014 8:08 am
Location: Omaha, NE

Re: Search result filter system

Post by chrisj »

lcarver wrote:This is very helpful, thank you to everyone who commented here!

JRtechw, the steps you outlined make sense to me, but I'm just starting to learn a bit of JS in order to build my own search filter buttons (I'm not a programmer... yet :lol: ). I want users to be able to see which filter they're choosing, rather than the dropdown list disappearing after a filter is selected. I'm wondering, did you ever get #4 working? If so, would you be willing to share more details of it?

Cheers,
Lexi
I have a project in which I am doing this, although I am not manipulating the string in the URL to accomplish it. Basically, I have a global search bar and several local search bars on product landing pages. When the search is active, it auto selects the appropriate filter.

I've also worked for a company that was able to get multiple search filters working, but it took a team of developers to figure it out, and the code was server side in AWS. Every year I put in a feature request for faceted search out of the box.
Chris Jones
Product Content Manager - TEAM Software
Image
akroeker
Jr. Propeller Head
Posts: 1
Joined: Thu Oct 23, 2014 1:06 pm

Re: Search result filter system

Post by akroeker »

Hi Chris,
I have a project in which I am doing this, although I am not manipulating the string in the URL to accomplish it. Basically, I have a global search bar and several local search bars on product landing pages. When the search is active, it auto selects the appropriate filter.
Did you ever get this working? I am trying to figure out how to have the global search bar search everything and then have a separate search bar that searches a search filter (without the user having to select a search filter in either search bar).

Thanks!

Amy
chrisj
Propeller Head
Posts: 87
Joined: Thu Jun 26, 2014 8:08 am
Location: Omaha, NE

Re: Search result filter system

Post by chrisj »

akroeker wrote:Hi Chris,
I have a project in which I am doing this, although I am not manipulating the string in the URL to accomplish it. Basically, I have a global search bar and several local search bars on product landing pages. When the search is active, it auto selects the appropriate filter.
Did you ever get this working? I am trying to figure out how to have the global search bar search everything and then have a separate search bar that searches a search filter (without the user having to select a search filter in either search bar).

Thanks!

Amy
Yes. I have a live site where this is working. There are definitely some strange Flare quirks with how I implemented it, but I'm relatively happy with the results. You can check it out here http://help.teamsoftware.com/Team-Unive ... y-Home.htm
Chris Jones
Product Content Manager - TEAM Software
Image
lcarver
Propeller Head
Posts: 17
Joined: Mon May 21, 2018 8:20 am

Re: Search result filter system

Post by lcarver »

Awesome! I hope MC adds more options for search, but in the meantime, I like the local search bars you added. Thanks for sharing!
Post Reply