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 204-209 OPAC: Link Here
204
            - a library select pulldown menu on the OPAC masthead.
204
            - a library select pulldown menu on the OPAC masthead.
205
        -
205
        -
206
            - 'Display this HTML when no results are found for a search in the OPAC:'
206
            - 'Display this HTML when no results are found for a search in the OPAC:'
207
            - '<br />Note: The placeholder {QUERY_KW} will be replaced with the keywords of the query.'
207
            - pref: OPACNoResultsFound
208
            - pref: OPACNoResultsFound
208
              type: textarea
209
              type: textarea
209
              class: code
210
              class: code
(-)a/opac/opac-search.pl (-1 / +8 lines)
Lines 736-741 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 {
740
            $template->param(
741
            $template->param(
741
                searchdesc => 1,
742
                searchdesc => 1,
Lines 744-749 for (my $i=0;$i<@servers;$i++) { Link Here
744
                query_cgi  => $query_cgi,
745
                query_cgi  => $query_cgi,
745
                limit_cgi  => $limit_cgi
746
                limit_cgi  => $limit_cgi
746
            );
747
            );
748
            (my $query_kw=$query_desc)=~s/ and|or / /g;
749
            my @query_kw=($query_kw=~ /([-\w]+\b)(?:[^,:]|$)/g);
750
            $query_kw=join('+',@query_kw);
751
            my $nohits=C4::Context->preference('OPACNoResultsFound');
752
            $nohits=~s/{QUERY_KW}/$query_kw/g;
753
            $template->param( 'OPACNoResultsFound' =>$nohits);
754
            $template->param(searchdesc => 1,query_desc => $query_desc,limit_desc => $limit_desc);
747
        }
755
        }
748
    } # end of the if local
756
    } # end of the if local
749
    # asynchronously search the authority server
757
    # asynchronously search the authority server
750
- 

Return to bug 7620