Sending a search with a leading space triggers a jquery error; this strips out leading (and trailing, just in case) spaces. --- opac/opac-search.pl | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/opac/opac-search.pl b/opac/opac-search.pl index a7f7470..4992e2f 100755 --- a/opac/opac-search.pl +++ b/opac/opac-search.pl @@ -331,6 +331,8 @@ my @results; ## I. BUILD THE QUERY ( $error,$query,$simple_query,$query_cgi,$query_desc,$limit,$limit_cgi,$limit_desc,$stopwords_removed,$query_type) = buildQuery(\...@operators,\...@operands,\...@indexes,\...@limits,\...@sort_by); + $query_desc =~ s/^\s+//; # removes leading space + $query_desc =~ s/\s+$//; # removes trailing space sub _input_cgi_parse ($) { my @elements; -- 1.5.6.5 _______________________________________________ Koha-patches mailing list Koha-patches@lists.koha.org http://lists.koha.org/mailman/listinfo/koha-patches