Problem with query params

  • Stefan
    Participant
    2 months, 2 weeks ago #45394

    Hi,
    My search page is located at the url /archiv
    in my search.php wordpress template, i add the SOLR search like this:

    echo do_shortcode( ‘[solr_search_shortcode]‘ );

    This does correctly show a search text field and the defined facets.

    If i enter ‘test’ in the search text field and hit search, i get redirected to /archiv/?search=test
    and all is as expected. But then, if i choose a value in one of the facets, i get redirected to
    /archiv/?wpsolr_q=test&wpsolr_fq%5B0%5D=article_publication_year_str%3A2012
    and then the search string ‘test’ is ignored.

    Any idea what is causing this and how to solve it?

    wpsolr
    Keymaster
    2 months, 2 weeks ago #45395

    The shortcode is deprecated, and instead you must use your current theme’s archive templates to display search results, with our widgets for facets and sort if necessary.

    Stefan
    Participant
    2 months, 2 weeks ago #45442

    Sorry, the documentation and forum entries are really confusing me.
    Can you point me to some current documentation on how to style the search page and search results?
    Are all the twig templates now also deprecated?
    And what about the search-page “search-wpsolr”? That also uses a shortcode, is that also deprecated?

    How does the ajax search work ?

    If I use this code in search.php, the problem with the querystring is still not solved:

    get_search_form();
    if ( is_active_sidebar( ‘custom-widget-area’ ) ) {
    dynamic_sidebar( ‘custom-widget-area’ );
    }

    wpsolr
    Keymaster
    2 months, 2 weeks ago #45443

    The purpose of WPSOlr is to replace archives’ SQL queries with an external search engine queries, more accurate and scalable.

    By selecting your theme’s templates on WPSolr screen 2.1, you keep your theme archive templates while benefiting from better search results:
    Theme archive template

    Select the archive SQL queries that need to be replaced:
    Image wpsolr_2_1_replace_front_end.png of

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.