Site logo

[Resolved] Unable to Get Search Results Template Working with Relevanssi

Home Forums Support [Resolved] Unable to Get Search Results Template Working with Relevanssi

Home Forums Support Unable to Get Search Results Template Working with Relevanssi

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #2576191
    Jonathan

    Hi there – I’m currently trying to build a search results template using the template loop and Relevanssi.

    Steps I’ve taken:
    1. Created an Element > Block > Content Template (Location: Search Results)
    2. Set up a query loop, inherit queries from template
    3. Set up Relevanssi premium (Out of the box, no PHP configuration)

    Effectively, I get a series of weird, unrelated results to the keyword.

    When I switch the template to Loop template, I get absolutely no results, as if the template is not even there.

    I am also using Max Mega Menu’s search box.

    What am I doing incorrectly?

    #2576275
    Fernando
    Customer Support

    Hi Jonathan,

    If you use a Content Template, you shouldn’t add a Query Loop Block.

    Here’s an article with a video showing how to create one: https://docs.generatepress.com/article/block-element-content-template/

    Can you try that and see how it goes?

    #2576287
    Jonathan

    I’ll give it a shot and see how it goes. In the meantime, is there anything I need to do with Relevanssi beyond initial setup?

    #2576297
    Fernando
    Customer Support

    Well, if a Block Element won’t work, you’ll like need to create a template for it.

    Example: https://generatepress.com/forums/topic/how-to-customize-search-results-template-to-add-relevanssi-excerpts/#post-483724

    #2580989
    Jonathan

    I was able to get this to work. Thank you!

    #2583297
    Fernando
    Customer Support

    You’re welcome, Jonathan!

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.