• Resolved slatejn

    (@slatejn)


    Given that I have FAQs for several different audiences, is there a way I can restrict or limit the search to a category and it’s children?

    My use case would be having a search on the “Web Forms” page for just forms and a separate search on the “Troubleshooting” page that doesn’t show anything from the Forms categories.

    [ultimate-faq-search include_category=’telecom-forms’]

    for example, is parsed, but returns no results. Because it returns nothing, the attribute appears to do do some kind of filtering.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Rustaurius

    (@rustaurius)

    Hi slate,

    You can use the same “include_category” and “exclude_category” attributes with the search shortcodes as you can with standard shortcode, so you should be able to have one form to search the “Web Forms” category and one to search everything else.

    Thread Starter slatejn

    (@slatejn)

    I attempted that a few different ways and search found no results. Specifically I tried the top level parent with 0 FAQs, but with populated children. Then I tried the bottom level children that have immediate FAQs. Neither returned any results nor did I get the autocomplete. The only thing that gave me results was the global search.

    Even then, the search doesn’t seem to match against Tags or a full title. Instead if I type “I can’t” I get 1 exact match in autocomplete, but when the full text is selected by clicking the auto complete, it returns results that contain any word in the title and makes me have to open 20 potential categories to find what autocomplete found.

    Thread Starter slatejn

    (@slatejn)

    Strange, It appears that Visual Composer has issues with some nested structures and added shortcode Tags randomly on the page which somehow broke the search. Even though the page/search field rendered properly and showed state changes (showed “no results”), it didn’t locate any FAQS. It is really odd behavior. I would expect the code to still execute but not render properly, or for the field to not render at all.

    After addressing the structure to display how I wanted it AND make the VC happy, I entered the Parent Category as an include filter and searched for a partial FAQ title.
    Looking at the results, it doesn’t seem to matter whether an exact title match is searched or the partial one. The Search return isn’t the FAQ but every category containing that faq. In this case that is 7 accordions returned for 1 FAQ.

    Contextually, returning seven categories makes sense if there was no direct match selected and you were doing a “find all in body and title”, however, with a direct match selected from autocomplete, it should only return that faq without a category or a single “Search Results” accordion. Otherwise, the only thing that makes sense to me would be to add an attribute toggle for the return display like:”[display_repeat_result_categories=’firstonly’] or [display_repeat_result_categories=’all’]”

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Search targeting (attributes)’ is closed to new replies.