View | Details | Raw Unified | Return to bug 7620
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref (+1 lines)
Lines 202-207 OPAC: Link Here
202
            - a library select pulldown menu on the OPAC masthead.
202
            - a library select pulldown menu on the OPAC masthead.
203
        -
203
        -
204
            - 'Display this HTML when no results are found for a search in the OPAC:'
204
            - 'Display this HTML when no results are found for a search in the OPAC:'
205
            - '<br />Note: The placeholder {QUERY_KW} will be replaced with the keywords of the query.'
205
            - pref: OPACNoResultsFound
206
            - pref: OPACNoResultsFound
206
              type: textarea
207
              type: textarea
207
              class: code
208
              class: code
(-)a/opac/opac-search.pl (-1 / +8 lines)
Lines 736-742 for (my $i=0;$i<@servers;$i++) { Link Here
736
            $template->param(next_page_offset => $next_page_offset) unless $pages eq $current_page_number;
736
            $template->param(next_page_offset => $next_page_offset) unless $pages eq $current_page_number;
737
        }
737
        }
738
        # no hits
738
        # no hits
739
        # extracting keywords in case of relaunching search
739
        else {
740
        else {
741
            (my $query_kw=$query_desc)=~s/ and|or / /g;
742
            $query_kw = Encode::decode_utf8($query_kw);
743
            my @query_kw=($query_kw=~ /([-\w]+\b)(?:[^,:]|$)/g);
744
            $query_kw=join('+',@query_kw);
745
            my $nohits=C4::Context->preference('OPACNoResultsFound');
746
            $nohits=~s/{QUERY_KW}/$query_kw/g;
747
            $template->param( 'OPACNoResultsFound' =>$nohits);
740
            $template->param(
748
            $template->param(
741
                searchdesc => 1,
749
                searchdesc => 1,
742
                query_desc => $query_desc,
750
                query_desc => $query_desc,
743
- 

Return to bug 7620