We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 26352
    • 21 Posts
    I've just integrated AdvSearch into a production version of our website (which is also making the move to Revo). I've been messing around with the styling and am hoping that someone can confirm that a "no results" message is not wrapped in any tags.

    I get a <p> tag and a class of ".advsea-results" if results are generated from the search, but nothing but the div that the snippet call is in if there are no results.

    Other than adding CSS to the outer div (which I really don't want to do, since I have everything measured in ems and I don't want any more crazy numbers), is there a way to do this?

    Thanks!


    This question has been answered by coroico. See the first response.

    • discuss.answer
      • 5811
      • 1,717 Posts
      You are right, It could be usefull to add a template for the "no results" search result. I will add this as an improvement for the next release.

      Otherwise to fix this problem without adding a div you could modify the lexicon 'advsearch.no_results' :

      For example:
      $_lang['advsearch.no_results'] = '<span class="flash">There were no search results. Please try using more general terms to get more results.</span>'; 
        • 26352
        • 21 Posts
        Thanks,

        I'll look forward to it ... and while we're talking about AdvSearch, I have another question. When somebody enters a search term, it gets echoed as part of the result. But the implementation I'm using for your snippet is all faceted search with 5 different inputs (some multi-select lists, some simple drop-downs).

        Is there a way to echo all the selections, as in "You searched for a and b from category 1 and c from category 2. Your search yielded n results."?

        Or instead, making the search selections "sticky" rather than clearing them out would probably also do the trick.

        Great plugin, coro, and thank you for your replies.

        Merci!
          • 22998
          • 52 Posts
          In $_lang['advsearch.no_results'] I need something like this: "There were no search results for [[+text]]. Please try using more general terms to get more results."[/s]
          But [[+text]] doesn't work here. How can I get request in advsearch.no_results?
            • 5811
            • 1,717 Posts
            Quote from: Pelya6 at Jan 16, 2014, 09:36 AM
            In $_lang['advsearch.no_results'] I need something like this: "There were no search results for [[+text]]. Please try using more general terms to get more results."[/s]
            But [[+text]] doesn't work here. How can I get request in advsearch.no_results?

            As specified in the documentation, did you try to use [[+searchValue]] instead of [[+text]] ?
              • 22998
              • 52 Posts
              Quote from: coroico at Jan 17, 2014, 11:33 AM

              As specified in the documentation, did you try to use [[+searchValue]] instead of [[+text]] ?

              I tried [[+searchValue]], but it doesn't work too sad